摘要: TASK 1 2004 2001 存放的数据类型不同 #include <stdio.h> #define N 4 int main() { int x[N] = {1, 9, 8, 4}; int i; int *p; for(i=0; i<N; ++i) printf("%d", x[i]); 阅读全文
posted @ 2022-06-13 22:01 workflame 阅读(17) 评论(2) 推荐(0) 编辑
摘要: TASK 1 因为数组本身就是地址。 //TASK1.1 #include <stdio.h> #define N 5 #define M 80 typedef struct { char name[M]; char author[M]; }Book; int main() { Book x[N] 阅读全文
posted @ 2022-06-06 21:47 workflame 阅读(27) 评论(2) 推荐(0) 编辑
摘要: TASK 1 ①是,2 ②不是,1 ③是,是 //task1.1// #include<stdio.h> #define N 4 int main() { int a[N]={2,0,2,2}; char b[N]={'2','0','2','2'}; int i; printf("sizeof(i 阅读全文
posted @ 2022-05-09 19:35 workflame 阅读(12) 评论(2) 推荐(0) 编辑
摘要: TASK 1 在80个输出0~25以内的行数和0~80以内的空格,再在随机输出的行数与空格后面输出“hi, MAY” #include<stdio.h> #include<stdlib.h> #include<time.h> #include<windows.h> #define N 80 void 阅读全文
posted @ 2022-04-25 21:25 workflame 阅读(26) 评论(2) 推荐(0) 编辑
摘要: TASK 1 1.生成2018到2021的随机整数 2.生成1~999以内的随机整数 3.生成一个学号 TASK 2 //TEXT 2// #include<stdio.h> #include<stdlib.h> #include<time.h> int main() { int luckyday, 阅读全文
posted @ 2022-04-17 13:34 workflame 阅读(26) 评论(2) 推荐(0) 编辑
摘要: #include <stdio.h> int main() { printf(" O\n"); printf("<H>\n"); printf("I I\n"); printf(" O\n"); printf("<H>\n"); printf("I I\n"); return 0; } #inclu 阅读全文
posted @ 2022-03-27 15:00 workflame 阅读(48) 评论(5) 推荐(0) 编辑