Paan is a library or source code that allows to easily fish out palindromes in a phrase, word or sentence. With PAAN, you can get all palindromes in a series of letters and the largest and smallest. Every block of code in the php source corresponds of code in the javascript source.
Usage Example:
$text = "AABMRRATFEDEFNABITTIBANTAADDFGFDFFDERTARRMBAABMRRATFEDEFNABITTIBANTA";
$palds = paan($text);
console.log($palds);
print_r($palds);
Calling the function returns an object with 3 elements:
Array (
"matches" #contains all the matched palindromes
"largest" #the longest palindrome
"smallest" #shortest palindrome
)
{
"matches" #contains all the matched palindromes
"largest" #the longest palindrome
"smallest" #shortest palindrome
}
** Incase of suggestions, feel free to open issues or contact me: joloashobatmat@gmail.com