Did you try these two Strings to see which is in order and which is not:
Xx
xX
The testing you describe would fail with these.
Type: Posts; User: Norm
Did you try these two Strings to see which is in order and which is not:
Xx
xX
The testing you describe would fail with these.
Your code will have to look at the case of each letter and consider that when comparing them.
Your code has a simple comparison:
if ( characters[i] > characters[i+1] )
This will have to be...
You definitely need the correct sorting sequence before you can write the code.
Do you understand my last post about 'X' being lower in value than 'a'?
That is what the ASCII values are.
If you...
I'm confused why those letters are not in ascending order. The ASCII values for the letters are:
X= \u0058
a= \u0061
b= \u0062
Based on that X comes before a which comes before b.
What...
To see what the code sees, add a prinln to print out the value of the input variable immediately after you read it in. Be sure to add delimiting Strings: println("input=" + input + "<") so you can...