| ||||||||||
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:用c又写了一遍,找到为什么wa了In Reply To:用c又写了一遍,找到为什么wa了 Posted by:bottles at 2009-03-16 19:42:11 > long long temp = 0; > while(n){ > temp += n % 10; > n /= 10; > temp *=10; > } > temp /=10; > > 这样写reverse函数的时候,一定要将temp 设为longlong ,因为在while里有可能超进度 Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator