Write a program that receives a number of arbitrary length as an input, and at the output gives out a number in direct form and the number vice versa on the next line. Solve the most rational way.
Input example: 7652 Output: 7 6 5 2 2 5 6 7
there is a solution through the lines and without spaces - I can finish them but the task is not for that
program revoptimal; var a:int64; begin readln(a); writeln(a); writeln(ReverseString(inttostr(a))); end.