Some comments on your code
- why would you want to have 2 for loops like
for(i='A';i<='Z';i++), if you can check this with a simple if statement ... you loop over a whole range while you can simply check whether it is contained in that range
- even when you found your answer (for example when input is
A you will have your result the first time you enter the first loop) you still loop over all the rest
- your
System.out.println("Lowercase"); statement (and the uppercase statement) are placed in the wrong loop
- If you are allowed to use it, I suggest to look at the
Character class which has for example nice isUpperCase and isLowerCase methods
I leave the rest up to you since it is homework