Simple While Loop Stuff
Posted on 2005-03-22
I have an algorithm from where I'm getting the results...something like this...
while(sp != NULL)
// Conversion from std::string to QString
if (sp == G.map[(G.find_node(G.map, source))])
ip1 = sp->name.c_str();
ip2 = sp->name.c_str();
sp = sp->next;
} // end of while
Ip1 gives me the first starting point and then , if you go further ip2 gives me the result ......this is based on Dijkstra Algorithm.....
suppose you say to want to go from A - D....so it comes like
first A -- result comes in ip1, then A ---> B---> result comes in ip2
then B--->D---> result comes in ip2
Ip2 value is changing all the time.....how can I grab all the values...
Its so stupid question for here....but can't get my brain to work....