fork download
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
  10.  
  11. public static <T extends Comparable<T>> void isPalindrome(T[] array)
  12. {
  13.  
  14. }
  15.  
  16. public static void main (String[] args) throws java.lang.Exception
  17. {
  18. Integer[] intArray = {1,2,5,7,9,0,7};
  19. Integer[] intArray2 = {1,1,2,2,2,2,1,1};
  20. String[] strArray = {"a","b","c","c","b","a"};
  21. String[] strArray2 = {"a","b","c","e","f","a"};
  22.  
  23.  
  24. isPalindrome(intArray);
  25. isPalindrome(intArray2);
  26. isPalindrome(strArray);
  27. isPalindrome(strArray2);
  28. }
  29. }
Success #stdin #stdout 0.08s 46644KB
stdin
Standard input is empty
stdout
Standard output is empty