<?php
$text = "к";
$result = "палиндром";
echo $text . "\n";
$halfLength = floor($length/2);
for ($i = 0; $i <= $halfLength; $i++) {
if ($left != $right) {
echo "Не полиндром";
break;
}elseif($i == $halfLength){
echo $result;
}
}
PD9waHAKZXJyb3JfcmVwb3J0aW5nKC0xKTsKbWJfaW50ZXJuYWxfZW5jb2RpbmcoJ3V0Zi04Jyk7CiR0ZXh0ID0gItC6IjsKJHJlc3VsdCA9ICLQv9Cw0LvQuNC90LTRgNC+0LwiOwokdGV4dCA9IG1iX3N0cnRvbG93ZXIoc3RyX3JlcGxhY2UoIiAiLCAiIiwkdGV4dCkpOwplY2hvICR0ZXh0IC4gIlxuIjsKJGxlbmd0aCA9IG1iX3N0cmxlbigkdGV4dCk7CiRoYWxmTGVuZ3RoID0gZmxvb3IoJGxlbmd0aC8yKTsKCmZvciAoJGkgPSAwOyAkaSA8PSAkaGFsZkxlbmd0aDsgJGkrKykgewoJJGxlZnQgPSBtYl9zdWJzdHIoJHRleHQsICRpLCAxKTsKCSRyaWdodCA9IG1iX3N1YnN0cigkdGV4dCwgLSRpLTEsIDEpOwoJaWYgKCRsZWZ0ICE9ICRyaWdodCkgewoJCWVjaG8gItCd0LUg0L/QvtC70LjQvdC00YDQvtC8IjsKCQlicmVhazsKCX1lbHNlaWYoJGkgPT0gJGhhbGZMZW5ndGgpewoJCWVjaG8gJHJlc3VsdDsKCX0KfQ==