📄 12.cpp
字号:
#include <iostream>
#include <fcntl.h>
#include <io.h>
using namespace std;
void mapshow(char* g)
{
int point;
int len;
point=_open(g,_O_RDONLY);
len=_filelength(point);
_close(point);
char* play=new char[len];
FILE *pfile;
pfile=fopen(g,"rb");
fread(play,len,1,pfile);
fclose(pfile);
int i=0;
while(i<len)
{
cout<<play[i];
i++;
}
cout<<endl;
delete[] play;
}
void main()
{
mapshow("西安.txt");
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -