<?php
$text = "А роза упала на лапу Азора";
$report = "";
for ($i = 0; $i < $lenght/2; $i++){
$lastSymbol = mb_substr($text, $lenght-1-$i, 1); if ($firstSymbol != $lastSymbol) {
$report = "Это не палиндром";
break;
} else {
$report = "Это палиндром";
}
}
echo "{$report}";
?>
PD9waHAKCmVycm9yX3JlcG9ydGluZygtMSk7Cm1iX2ludGVybmFsX2VuY29kaW5nKCd1dGYtOCcpOwoKJHRleHQgPSAi0JAg0YDQvtC30LAg0YPQv9Cw0LvQsCDQvdCwINC70LDQv9GDINCQ0LfQvtGA0LAiOwoKJHRleHQgPSBtYl9zdHJ0b2xvd2VyKCR0ZXh0KTsKJHRleHQgPSBzdHJfcmVwbGFjZSgiICIsICIiLCAkdGV4dCk7CgokcmVwb3J0ID0gIiI7CgokbGVuZ2h0ID0gbWJfc3RybGVuKCR0ZXh0KTsKCmZvciAoJGkgPSAwOyAkaSA8ICRsZW5naHQvMjsgJGkrKyl7CgkkZmlyc3RTeW1ib2wgPSBtYl9zdWJzdHIoJHRleHQsICRpLCAxKTsKCSRsYXN0U3ltYm9sICA9IG1iX3N1YnN0cigkdGV4dCwgJGxlbmdodC0xLSRpLCAxKTsKCWlmICgkZmlyc3RTeW1ib2wgIT0gJGxhc3RTeW1ib2wpIHsKCQkkcmVwb3J0ID0gItCt0YLQviDQvdC1INC/0LDQu9C40L3QtNGA0L7QvCI7CgkJYnJlYWs7Cgl9ICBlbHNlIHsKCQkkcmVwb3J0ID0gItCt0YLQviDQv9Cw0LvQuNC90LTRgNC+0LwiOwoJfQp9CgplY2hvICJ7JHJlcG9ydH0iOwoKPz4=