📄 fileope.cpp
字号:
#include <fstream>
#include <iostream>
using namespace std;
int main()
{
ifstream fin("input.txt");
ofstream fout("output.txt");
int number;
float real;
char letter, word[8];
char sentence[101];
int num=100;
char name[]="John Doe";
fout << "Here is a number: " << num << "\n";
fout << "Now here is a string: " << name << "\n";
fin>>number>>real>>letter>>word;
fin.getline(sentence,100);
return 0;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -