Skip to content

Instantly share code, notes, and snippets.

@shintack
Last active May 12, 2019 03:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shintack/83ff8e7480ca7517d2223ae8a10adec8 to your computer and use it in GitHub Desktop.
Save shintack/83ff8e7480ca7517d2223ae8a10adec8 to your computer and use it in GitHub Desktop.
Palindrome
<?php
class Palindrome
{
public static function isPalindrome($word)
{
$word = strtolower($word);
return $word===strrev($word);
}
}
echo Palindrome::isPalindrome('Deleveled');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment