还有1天复赛。

文化课太 ** 的 ** 了

考试注意事项相关

携带物品

  • 准考证
  • 参赛证
  • 身份证
  • 承诺书
  • 健康码

时间地点

地点

南开中学北院翔宇楼五楼机房

时间

7:50进场试机

8:30开始比赛

12:00结束

文件相关

后缀名

test.cpp

存储

D盘下建立以准考证号为名的文件夹

并给每个题目建立子文件夹

记得删除无用文件

算法相关

程序框架(?)

1
2
3
4
5
6
7
8
#include<iostream>
using namespace std;
int main(){

//code here

return 0;
}

C输入输出

头文件

1
#include<cstdio>

输入:

1
scanf("%d",&a);

输出:

1
printf("a是%d",a);

其中,第一个参数是占位符,常用占位符:

  • %d int
  • %l64d longlong(windows)
  • %lld longlong(Linux)
  • %f float double(输出)
  • %lf double(读入)
  • %.2f 保留两位小数
  • %c char
  • %s string

文件重定向

头文件

1
#include<cstdio>

在主函数里加上:

1
2
3
4
5
freopen("test.in","r",stdin);
freopen("test.out","w",stdout);
//code here
fclose(stdin);
fclose(stdout);

写在最后

rp++;

全篇字少事大.

end.

by X3B0A1