fork download
  1. import java.util.*;
  2. import java.lang.*;
  3. import java.io.*;
  4.  
  5. class Ideone
  6. {
  7. public static void main (String[] args) throws java.lang.Exception
  8. {
  9. String word1 = "uniunea";
  10. String word2 = "EUROPEANA";
  11.  
  12. String varUpper = word1.toUpperCase();
  13. String varLower = word2.toLowerCase();
  14.  
  15. String combine = word1 + " " + word2;
  16. String combineREV = varUpper + " " + varLower;
  17.  
  18. System.out.println(combine);
  19. System.out.println(combineREV);
  20. System.out.println("*" + combineREV.charAt(0) + combineREV.charAt(combineREV.length() - 1) + "*");
  21. }
  22.  
  23. }
Success #stdin #stdout 0.15s 50744KB
stdin
Standard input is empty
stdout
uniunea EUROPEANA
UNIUNEA europeana
*Ua*