C++ 输入输出流和文件流 (2010-01-17 13:34:03)http://blog.sina.com.cn/s/blog_700a65cc0100mi5o.html
来源:互联网 发布:软件开发项目成果 编辑:程序博客网 时间:2024/06/05 03:50
C++ 输入输出流和文件流
(2010-01-17 13:34:03)转载▼
标签:
程序设计
分类: 程序内置数据类型,并不用考虑数据转换层面的东西。例如:
int i;
cin >> i;
或者
string s;
cin >> s;
都是正确的表达,只要使用程序的人清楚,什么地方需要输入什么类型的数据就可以了。
#include <iostream>
#include <fstream>
#include <string>
using namespace std;
int main()
{
}
如果a.txt中的内容是
139
43
987
则执行程序之后,b.txt中内容是
139
987
c.txt中内容是
43
0 0
- C++ 输入输出流和文件流 (2010-01-17 13:34:03)http://blog.sina.com.cn/s/blog_700a65cc0100mi5o.html
- PDP 上下文 (2011-03-31 17:40:27) http://blog.sina.com.cn/s/blog_798a531d0100qe9q.html
- http://blog.sina.com.cn/s/blog_5f8817250100g1dj.html
- http://blog.sina.com.cn/s/blog_5dfb7f4d0100j5e6.html
- http://blog.sina.com.cn/s/articlelist_1587621077_0_1.html
- http://blog.sina.com.cn/s/blog_8820018a0100w7t7.html
- http://blog.sina.com.cn/s/articlelist_1973273451_0_1.html
- http://blog.sina.com.cn/s/articlelist_1454293451_0_1.html
- http://blog.sina.com.cn/s/articlelist_1229508141_0_1.html
- http://blog.sina.com.cn/s/blog_4e6dffee0100hid1.html
- http://blog.sina.com.cn/s/blog_4ac0a0d30100cp9d.html
- http://blog.sina.com.cn/s/blog_77dd2fd20100y9vc.html
- http://blog.sina.com.cn/s/blog_61d8dfdb0100fti3.html
- http://blog.sina.com.cn/s/blog_65e943e70101est7.html
- http://blog.sina.com.cn/s/blog_8337d0c50100xn1p.html
- http://blog.sina.com.cn/s/blog_43eb83b90102dyl3.html
- http://blog.sina.com.cn/s/blog_3fe961ae01012tid.html
- http://blog.sina.com.cn/s/blog_53828e460100mv0d.html
- CodeForces 441A Valera and Antique Items
- 一个字符串排序的程序
- 《HeadFirst JavaScript》学习笔记
- Linux内核构建系统之二
- Activity后台运行一段时间回来crash问题的分析与解决
- C++ 输入输出流和文件流 (2010-01-17 13:34:03)http://blog.sina.com.cn/s/blog_700a65cc0100mi5o.html
- 数据结构与算法——给定整数A1,A2,....An,....(可能有负数),求该数据序列的最大子序列的和
- Unity不规则碰撞
- 插件升级“无法定位 WordPress 内容目录”
- struts + mybatis +spring实现黑名单/灰名单管理
- 单台机器上设置多个域名,二级域名绑定到子目录
- Swift之多线程
- MYSQL学习
- linux 内核模块编程之编译多个源文件(三)