会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
zhaoRR
博客园
首页
新随笔
联系
订阅
管理
2022年6月12日
实验6 指针
摘要: //1_1 #include <stdio.h> #define N 4 int main() { int x[N] = {1, 9, 8, 4}; int i; int *p; // 方式1:通过数组名和下标遍历输出数组元素 for(i=0; i<N; ++i) printf("%d", x[i]
阅读全文
posted @ 2022-06-12 19:34 刺刺球
阅读(19)
评论(2)
推荐(0)
2022年6月6日
实验5 结构体和文件
摘要: //1_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 22:41 刺刺球
阅读(39)
评论(2)
推荐(0)
2022年5月10日
实验4 数组
摘要: //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(int) = %d\n
阅读全文
posted @ 2022-05-10 01:11 刺刺球
阅读(31)
评论(2)
推荐(0)
2022年4月25日
实验3 函数
摘要: //task1 #include <stdio.h> #include <stdlib.h> #include <time.h> #include <windows.h> #define N 80 void printText(int line, int col, char text[]); //
阅读全文
posted @ 2022-04-25 14:23 刺刺球
阅读(17)
评论(2)
推荐(0)
2022年4月17日
实验2 C语言控制语句应用编程
摘要: //task1 #include <stdio.h> #include <stdlib.h> #include <time.h> #define N 5 int main() { int grade, number; int i; srand(time(0));// 以当前系统时间作为随机种子 fo
阅读全文
posted @ 2022-04-17 13:30 刺刺球
阅读(30)
评论(2)
推荐(0)
2022年3月26日
实验1 C语言开发环境使用和编程初体验
摘要: //task1_1 #include <stdio.h> int main() { int i = 1; while (i < 3) { printf(" O\n"); printf("<H>\n"); printf("I I\n"); printf("\n"); i++; } return 0;
阅读全文
posted @ 2022-03-26 14:32 刺刺球
阅读(51)
评论(3)
推荐(0)
公告