<?php
$text = "А роза упала на лапу Азора";
$result = "Палиндром";
$negative = "не палиндром";
for ($i = 1; $i <= $length; $i++){
if ($letter1 != $letter2) {
echo "$letter1 - $letter2\n$negative";
break;
}
elseif ($i == $length){
echo "$result";
} else {
echo "$letter1 - $letter2\n";
}
}
PD9waHAKCmVycm9yX3JlcG9ydGluZygtMSk7Cm1iX2ludGVybmFsX2VuY29kaW5nKCd1dGYtOCcpOwoKJHRleHQgPSAi0JAg0YDQvtC30LAg0YPQv9Cw0LvQsCDQvdCwINC70LDQv9GDINCQ0LfQvtGA0LAiOwokcmVzdWx0ID0gItCf0LDQu9C40L3QtNGA0L7QvCI7CiRuZWdhdGl2ZSA9ICLQvdC1INC/0LDQu9C40L3QtNGA0L7QvCI7CiR0ZXh0ID0gbWJfc3RydG9sb3dlcigkdGV4dCk7CiR0ZXh0ID0gc3RyX3JlcGxhY2UoIiAiLCAiIiwgJHRleHQpOwokbGVuZ3RoID0gZmxvb3IgKG1iX3N0cmxlbigkdGV4dCkgLyAyKTsKCmZvciAoJGkgPSAxOyAkaSA8PSAkbGVuZ3RoOyAkaSsrKXsKCSRsZXR0ZXIxID0gbWJfc3Vic3RyKCR0ZXh0LCAkaS0xLCAxKTsKCSRsZXR0ZXIyID0gbWJfc3Vic3RyKCR0ZXh0LCAtJGksIDEpOwoJaWYgKCRsZXR0ZXIxICE9ICRsZXR0ZXIyKSB7CiAJZWNobyAiJGxldHRlcjEgLSAkbGV0dGVyMlxuJG5lZ2F0aXZlIjsKIAlicmVhazsKICAgIH0JCiAgICBlbHNlaWYgKCRpID09ICRsZW5ndGgpewoJZWNobyAiJHJlc3VsdCI7Cgl9IGVsc2UgewoJZWNobyAiJGxldHRlcjEgLSAkbGV0dGVyMlxuIjsKCX0KfQ==