Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ifndef _INCLUDE_GRAPH_
- #define _INCLUDE_GRAPH_
- #pragma once
- #define SPEED 4
- typedef struct NItem
- {
- int nKey; //nr wierzchołka sąsiada
- double length; //długość
- double time; //czas
- NItem* pNext; //na kolejne pudelko w liscie sasiedzsta
- }List;
- typedef struct
- {
- List* nList; //Lista sąsiedztw
- int Type; //Shop or not
- int NearestShop; //indeks najblizszego sklepu
- double WayToShop; //suma dlugosci
- int* WhichVertex; //nr węzła który jest najbliższym sklepem
- double TimeAll; //czas przejścia całości
- }Vertex;
- double Dijkstra( Vertex*, int, int); // tu trzeba uzyc headera z prior queue
- void DFS(Vertex*, int, int*); // metoda przegladania grafu w glab obliczyc czasy przejscia pomiedzy wierzcholkami
- #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement