var a,b:array[0..200]of integer;
c:array[0..400]of integer;
i,j,len,la,lb:integer;
x:longint;
sa,sb:string;
begin
readln(sa);
readln(sb);
if (sa='0')or(sb='0')then begin
writeln(0);
halt;
end;
la:=length(sa);
lb:=length(sb);
for i:=la downto 1 do a[la-i+1]:=ord(sa[i])-48;
for i:=lb downto 1 do b[lb-i+1]:=ord(sb[i])-48;
for i:=1 to la do
for j:=1 to lb do c[i+j-1]:=c[i+j-1]+a[i]*b[j];
len:=la+lb;
for i:=1 to len do begin
c[i+1]:=c[i+1]+c[i] div 10;
c[i]:=c[i] mod 10;
end;
while c[len]=0 do len:=len-1;
x:=c[len];
while x>0 do begin
c[len]:=x mod 10;
x:=x div 10;
len:=len+1;
end;

for i:=len-1 downto 1 do write(c[i]);
end.
为什么只有50分?

0 条评论

目前还没有评论...

信息

ID
1040
难度
7
分类
高精度 点击显示
标签
(无)
递交数
16500
已通过
3153
通过率
19%
被复制
23
上传者