Ask
your own question, for FREE!
Computer Science
21 Online
A link list problem, i need some how to sort and print out an object by surname in alphabetical order. i have a try to do that by this code not working for swamping i should i go about that? void functions::printdata() { for(node* temp1=head;temp1!=NULL;temp1=temp1->next) { for(node* temp2=head;temp2!=NULL;temp2=temp2->next) { if(temp2->client.getsurname() > temp1->client.getsurname()) { clienttype swap=temp1->client; temp1->client=temp2->client; temp2->client=swap; } } }
Still Need Help?
Join the QuestionCove community and study together with friends!
Did you try looking at the values and types of your assorted objects to make sure you don't have any oddities happening there? Like an address getting confues with a value.
Oh i joke my self with it.
Can't find your answer?
Make a FREE account and ask your own questions, OR help others and earn volunteer hours!
Join our real-time social learning platform and learn together with your friends!
Join our real-time social learning platform and learn together with your friends!
Latest Questions
xXAikoXx:
Does anybody else have rapid changes in their weight? Sometimes I would lose a lot of weight, gain more, lose again, and the cycle continues lol.
Shadowandsage:
The Ghost (I did the story for a fan bc they asked on their message so now am seeing if u guys like it so this is second attempt) I was driving to the woods
breiadabrattzz:
Anyone opinons on the gurl tht died on the train or the guy tht got beheaded in m
MAGABACK:
WHY WAS CHARLIE KIRK ASSASINATED? WHY DID THAT NEED TO HAPPEN?????????????
TheVoid:
[b] Tv show script - Feedback wanted! [/b] Different parts will be put in respons
3 hours ago
13 Replies
1 Medal
1 day ago
5 Replies
0 Medals
13 hours ago
17 Replies
0 Medals
2 days ago
78 Replies
3 Medals
1 day ago
6 Replies
0 Medals