Skip to content

shwehy/Graphs-FinalProject

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 

Repository files navigation

Graphs-FinalProject

3 projects on graphs and path

Program 1 Program description: The idea of this program is based on connected graphs such as what we see in LinkedIn connections. The aim of the program is to get the total number of people connected at kth vertices away from each other where the user is asked to enter number of vertices (number of people) , number of edges (connections between people) , the value of edges, starting vertex and the value of k. The program will print out the number of people that are k vertices away from starting vertex. Program 2 Program description: This program is a maze of NxN matrix where the user is asked to enter the value of “N” then to fill the matrix. The matrix must be filled with 0s and 1s only as 0 represents an allowed cell and 1 represents a blocked cell that can’t be moved through. The start point is at (0,0), the required destination is at (N-1, N-1) and there are 4 possible directions (up - down – right - left). If there is a possible and allowed path from the start point to the destination point, the program prints out the path to the user and if there isn’t any possible path, the program prints out that there is no path. Program 3 Program description: There are some cities and some routes connecting specific cities and for each route between two cities there is a flight with specific time and cost. The aim of this program is to find the route with the minimum cost to travel from city X to city Y. For every hour spent waiting in the airport for another flight, amount of dollars had to be paid. The waiting time is always one hour by default. The user is asked to enter the amount of money lost per hour, number of cities, number of existing routes, cost and time for each flight, source and destination cities. The route with the minimum cost will be printed out with its total time and cost after entering all the required data by the user.

Releases

No releases published

Packages

No packages published

Languages