Name: Anonymous 2009-09-21 5:37
i do not for the life of me understand how this string variable works in c++.
i'd rather do this using a regular char array and strcmp functions but i'm trying to help a friend with his c++ home work and i cannot get this to work. i don't usually code c++ but i didn't think it would be that much different from c...
http://www.pastie.org/624362
biggest issues are using .compare with the string because i know i can store the entered string like this.
also if i uncomment the goto line it will get stuck in an endless loop if i enter any dots and lines, which is very weird. entering abc doesn't do it but entering morse code with dots, lines and white spaces causes the program to just go around and round displaying all the menus but automatically entering the dots and looping away. what's wrong with dots?
i'd rather do this using a regular char array and strcmp functions but i'm trying to help a friend with his c++ home work and i cannot get this to work. i don't usually code c++ but i didn't think it would be that much different from c...
http://www.pastie.org/624362
biggest issues are using .compare with the string because i know i can store the entered string like this.
also if i uncomment the goto line it will get stuck in an endless loop if i enter any dots and lines, which is very weird. entering abc doesn't do it but entering morse code with dots, lines and white spaces causes the program to just go around and round displaying all the menus but automatically entering the dots and looping away. what's wrong with dots?