Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

Re:用c又写了一遍,找到为什么wa了

Posted by sherlockjk at 2009-07-30 09:52:50 on Problem 1504
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:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator