- 博客(2)
- 收藏
- 关注
转载 cin ,getchar,gets,scanf区别
<br />1. cin,cin.get,cin.getline<br />cin读入数据遇到空格结束;丢弃空格符,输入回车符结束,很正常。<br />cin.get用来读取字符,输入回车符结束,但是不丢弃回车符和空格符。<br />注意:cin.get()与cin.get(char)等价,但是cin.get(char *,int) 用来读取字符串,可以接受空格符,遇到回车符结束,按照指定长度(长度减1)读取字符, 会丢弃最后的回车符。<br />cin.getline()与cin.get(
2010-11-20 17:16:00
553
原创 Cubic-free numbers I
<br /><br /> Cubic-free numbers ITime Limit: 1 Sec Memory Limit: 128 MB<br />Submissions: 312 Solved: 149<br />Description<br />A positive integer n is called cubic-free, if it can't be written in this form n = x*x*x*k, while x is a positive integer
2010-11-20 16:35:00
287
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅