- 曹冲养猪
- 2012-11-06 22:35:37 @
var
n,a,b,c,d,e:longint;
x:array[1..1000,1..1000]of longint;
begin
read(n);
for a:=1 to n do
read(x[1,a],x[2,a]);
for a:=1 to n do
if x[2,a]>c then c:=x[2,a];
while d=0 do begin c:=c+1;
for a:=1 to n do
if ((c-x[2,a])mod(x[1,a]))=0 then b:=b+1;
if b=n then d:=1;
end;
write(c);
end.
程序没问题,不知错误。求解给Q币
1 条评论
-
ckck LV 7 @ 2014-08-26 20:43:38
...没看出来
- 1