摘要:
由于Linux下没有gets函数,所以提示函数警告 warning: the `gets' function is dangerous and should not be used.用fgets代替就行了。函数算在头文件:#include 函数原型: int fgetc(FILE *st... 阅读全文
posted @ 2017-05-25 21:01 蓝空 阅读(1513) 评论(0) 推荐(0) 编辑
|
||
摘要:
由于Linux下没有gets函数,所以提示函数警告 warning: the `gets' function is dangerous and should not be used.用fgets代替就行了。函数算在头文件:#include 函数原型: int fgetc(FILE *st... 阅读全文
posted @ 2017-05-25 21:01 蓝空 阅读(1513) 评论(0) 推荐(0) 编辑
摘要:
原网址:here有时用了freopen,怎么搞都不能从控制台输入输出了,相当郁闷。于是总结了一下用freopen后恢复到控制台的方法。方法一、 在freopen前,调用dup把标准输出的文件描述符保存起来 old = _dup( 1 ); ... 阅读全文
posted @ 2017-05-25 20:54 蓝空 阅读(788) 评论(0) 推荐(0) 编辑 |
||