I did the nested if and it worked. Thanks for your help
Type: Posts; User: KristopherP
I did the nested if and it worked. Thanks for your help
I tried your suggestion with
if( size > 0)
{
answer = input.charAt(0);
}
When I get to the next part it tells me answer is not initialized
So if I added something like this to check the length of the string, where would I need to add it to prevent the crash? Would I had a comparison to my if statement?
int size;
size =...
I am having trouble with my program. I finished it but, I can not get the begging to cooperate. I need to take a users input if they would like to play a game. I have to use the charAt method to...