Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
Re:完全无法理解为何错的弱菜路过……In Reply To:完全无法理解为何错的弱菜路过…… Posted by:bleach35 at 2012-05-07 20:34:09 > program poj2316; > var i,j,k,n,m,tot:longint; > ss:string; > ans:array [1..20] of int64; > > begin > //assign(input,'a.in');reset(input); > readln(ss); > for i:=1 to length(ss) do > Val(ss[i],ans[i]); > while not eof do > begin > readln(ss); > for i:=1 to length(ss) do > ans[i]:=ans[i]+ord(ss[i])-48; > end; > for i:=1 to length(ss) do > write(ans[i] mod 10); > writeln; > //close(input); > end. Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator