I'm writing a translator program, and I'm confused about a certain part. The project description asks for you to sometimes take a char and turn it into something that has more than one letter. what's an easy way to do this since I already use strchr() to find the letter. Replacing it with one letter is no prob, but trying to change the one char into multiple letters...I'm wracking my brain and can't think of a solution. :confused:
Any help is greatly appreciated.
you could switch it:
while( letter != '.' )
switch( letter )
cout << "aa"; //or whatever you want to do with it