fork download
  1. public class Main
  2. {
  3.  
  4.  
  5. public static void main(String[] args) {
  6.  
  7. for(int i=0; i<Character.MAX_VALUE; i++) {
  8. for(int j=i+1; j<Character.MAX_VALUE; j++) {
  9. char a = (char) i;
  10. char b = (char) j;
  11. if(Character.toLowerCase(a)!=Character.toLowerCase(b) &&
  12. Character.toUpperCase(a)==Character.toUpperCase(b)) {
  13. System.out.println("Lowercase is not enough: "+i+" "+j);
  14. }
  15. if(Character.toLowerCase(a)==Character.toLowerCase(b) &&
  16. Character.toUpperCase(a)!=Character.toUpperCase(b)) {
  17. System.out.println("Uppercase is not enough: "+i+" "+j);
  18. }
  19. if(Character.toLowerCase(a)!=Character.toLowerCase(b) &&
  20. Character.toUpperCase(a)!=Character.toUpperCase(b) &&
  21. Character.toLowerCase(Character.toUpperCase(a))==Character.toLowerCase(Character.toUpperCase(b))
  22. ) {
  23. System.out.println("Neither is enough: "+i+" "+j);
  24. }
  25. }
  26. }
  27.  
  28. }
  29. }
  30.  
Time limit exceeded #stdin #stdout 5s 380352KB
stdin
Standard input is empty
stdout
Uppercase is not enough: 73 304
Lowercase is not enough: 73 305
Uppercase is not enough: 75 8490
Lowercase is not enough: 83 383
Uppercase is not enough: 105 304
Lowercase is not enough: 105 305
Uppercase is not enough: 107 8490
Lowercase is not enough: 115 383
Lowercase is not enough: 181 924
Lowercase is not enough: 181 956
Uppercase is not enough: 197 8491
Uppercase is not enough: 223 7838
Uppercase is not enough: 229 8491
Neither is enough: 304 305