Òzyf2010 2010-07-19 00:38:00
点我顶贴
收藏
删除
var
i,t,j,ch:longint;
s1,s:string;
begin
readln(s);
i:=pos(' ',s);
s1:=copy(s,1,i-1);
delete(s,1,i);
t:=0;
for i:=1 to length(s1) do
begin
ch:=ord(s1[i])-ord('0');
for j:=1 to length(s) do
t:=t+ch*(ord(s[j])-ord('0'));
end;
writeln(t);
end.