Empresa activa
Write a function to determain if a string is Palindrome?
Anónimo
use two pointer left and right in a while loop. check whether char at left equals to right. if yes, left++ and right--, if not, return false.
public static boolean isPalindrome(String text, int start, int end){ if (text == null) { return false; } if (start >= end) { return true; } if (text.charAt(start) != text.charAt(end)) { return false; } return isPalindrome(text,start+1,end-1); }
Sigue a tus empresas favoritas para estar al tanto de las últimas oportunidades y disponer de información de primera mano.
Recibe recomendaciones y actualizaciones personalizadas al iniciar tu búsqueda.