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

255长度绝对可信!

Posted by DavidDyn at 2019-10-28 00:59:17 on Problem 3094
gets函数返回的字符串包括了换行符和结尾的'\0'。换行符最长的情况就是"\r\n"两个字节,再加上'\0'一共是三个字节。亲测,将数组开到255+3=258字节,AC。

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