Created
January 14, 2014 16:18
-
-
Save fhferreira/8420933 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function palindromes($words) { | |
$str = ""; | |
// Write your code here | |
foreach($words as $word){ | |
if( $word == strrev($word) ){ | |
$str .= 'T'; | |
}else{ | |
$str .= 'F'; | |
} | |
} | |
return $str; | |
// To print results to the standard output you can use print | |
// Example: | |
// print "Hello world!"; | |
} | |
// Do NOT call the palindromes function in the code | |
// you write. The system will call it automatically. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment