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:为什么while(cin>>s>>t)能过而把cin写在while(1)里面就OLE?

Posted by Desertangle at 2010-05-04 10:33:29 on Problem 1936
In Reply To:为什么while(cin>>s>>t)能过而把cin写在while(1)里面就OLE? Posted by:o0Fancy0o at 2008-09-22 21:45:54
> 为什么while(cin>>s>>t)能过而把cin写在while(1)里面就OLE?
while(1)是死循环,永远跳不出来...
而while(cin>>s>>t)是根据cin是否有效判断,cin无效,代表输入结束,一般是文件结束符好像,不太记得了.呵呵..我也就知道这些了...

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