<html>
<head>
<title> palindrome</title>
</head>
<?php
function pal()
{
$s=121;
$p=strrev($s);
if(strcmp($s,$p)==0)
{
echo " palindrome";
}
else
{
echo "not palindrome";
}
} pal();
?>
</body>
</html>
<head>
<title> palindrome</title>
</head>
<?php
function pal()
{
$s=121;
$p=strrev($s);
if(strcmp($s,$p)==0)
{
echo " palindrome";
}
else
{
echo "not palindrome";
}
} pal();
?>
</body>
</html>
No comments:
Post a Comment