예제 #1
0
 private static boolean isPalindrome(BigInteger n) {
   return n.toString().equals(join(reverse(asList(Utility.digits(n.toString()))), ""));
 }
예제 #2
0
 private static BigInteger reverseAndAdd(BigInteger n) {
   return n.add(new BigInteger(join(reverse(asList(Utility.digits(n.toString()))), "")));
 }