Guest User

Untitled

a guest
Jul 19th, 2018
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.17 KB | None | 0 0
  1. bool palindrome(char* s, int len)
  2. {
  3.     if (len > 0)
  4.     {
  5.         if (s[0] == s[len-1] && palindrome(++s, len-2))
  6.             return true;
  7.            
  8.         return false;
  9.     }
  10.    
  11.     return true;
  12. }
Add Comment
Please, Sign In to add comment