Back to Problem Solutions forum
Hi guys. I have solved the palidrom problem and get the correct answer but when i try to complie my source code here, in service I get the error "CPU time limit exceeded (core dumped)". Is that becouse my code sucks or what? It looks like this http://pastebin.com/ScuTAjZb
Hi! I see that colleague Quandray left the comment for your solution. funny: I thought no one uses comments at all
Your code probably could be made somewhat faster (palindrom problems have some funny approaches, I believe), but this problem does not require you to write optimal code :)
However the service which helps us running codes in site have some limitations - among them on execution time. As long as you can run the code at your own machine this will not create much trouble for you, I hope.
A ok, but i found the issue. At the end of the imput text there is no new line ("\n") character thats why my program fails on the server.