improvement of finding palindrome with speed O(N^2)