简单解法

P1307 [NOIP2011 普及组] 数字反转

xyy2396 @ 2017-04-01 19:20:23

var n,s:longint;
begin
  read(n);
  while n<>0 do
    begin
      s:=s*10+n mod 10;
      n:=n div 10;
    end;
  writeln(s); 
end.

by outlooker @ 2017-04-01 21:35:22

题解里早就有了


by 真·五河士道 @ 2017-04-06 20:50:05

不太懂


by 野·浪子 @ 2017-04-14 12:18:59

啥意思啊


|