04 2021 档案

摘要:#include <stdio.h> long long fun(int n); int main() { int n; long long f; while(scanf("%d", &n) != EOF) { f = fun(n); // 函数调用 printf("n = %d, f = %lld 阅读全文
posted @ 2021-04-29 22:21 马永璨 阅读(27) 评论(3) 推荐(0) 编辑
摘要:// 生成N个0~99之间的随机整数,并打印输出 #include <stdio.h> #include <stdlib.h> #include <time.h> #define N 5 int main(){ int x, n; srand(time(0)); // 以当前系统时间作为随机种子 f 阅读全文
posted @ 2021-04-15 22:44 马永璨 阅读(60) 评论(3) 推荐(0) 编辑
摘要://格式化输入、输出函数的简单运用 #include <stdio.h> int main(){ int num; scanf("%d",&num); printf("2049%04d\n", num); scanf("%d",&num); printf("2049%04d\n", num); sc 阅读全文
posted @ 2021-04-01 22:04 马永璨 阅读(142) 评论(3) 推荐(0) 编辑