• 博客园logo
  • 会员
  • 周边
  • 新闻
  • 博问
  • 闪存
  • 众包
  • 赞助商
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
 






lihenn

 
 

Powered by 博客园
博客园 | 首页 | 新随笔 | 联系 | 订阅 订阅 | 管理

2025年12月31日

实验七
摘要: 实验任务4 #include <stdio.h> int main(){ FILE *fp; fp=fopen("data4.txt","r"); int line=0,chars=0; char ch; if(!fp){ perror("data4.txt"); return 1; } while 阅读全文
posted @ 2025-12-31 18:40 黎恆 阅读(8) 评论(1) 推荐(0)
 

2025年12月24日

实验六
摘要: 任务四 、 #include<stdio.h> #define N 10 typedef struct { char isbn[20]; char name[80]; char author[80]; double sales_price; int sales_count; }Book; void 阅读全文
posted @ 2025-12-24 11:04 黎恆 阅读(5) 评论(1) 推荐(0)
 

2025年12月12日

实验五
摘要: task 1.1 #include <stdio.h> #define N 5 void input(int x[], int n); void output(int x[], int n); void find_min_max(int x[], int n, int *pmin, int *pma 阅读全文
posted @ 2025-12-12 13:12 黎恆 阅读(4) 评论(1) 推荐(0)
 

2025年11月16日

实验四
摘要: #include <stdio.h> #define N 4 #define M 2 void test1() { int x[N] = {1, 9, 8, 4}; int i; // 输出数组x占用的内存字节数 printf("sizeof(x) = %d\n", sizeof(x)); // 输 阅读全文
posted @ 2025-11-16 14:08 黎恆 阅读(8) 评论(1) 推荐(0)
 

2025年10月30日

实验三
摘要: 任务一 #include<stdio.h> char score_to_grade(int score) ; int main() { int score; char grade; while(scanf("%d", &score) != EOF) { grade = score_to_grade( 阅读全文
posted @ 2025-10-30 11:48 黎恆 阅读(13) 评论(1) 推荐(0)
 

2025年10月16日

实验二
摘要: #include <stdio.h> #include <stdlib.h> #include <time.h> #define N 5 #define N1 80 #define N2 35 int main() { int cnt; int random_major, random_no; sr 阅读全文
posted @ 2025-10-16 21:08 黎恆 阅读(13) 评论(1) 推荐(0)
 

2025年10月8日

实验1
摘要: 实验任务2//从键盘上输入三个数据作为三角形边长,判断其能否构成三角形 //构成三角形的条件;任意两边之和大于第三边 #include <stdio.h> int main() { double a,b,c; //输入三边边长 scanf("%lf%lf%lf",&a,&b,&c); //判断能否构 阅读全文
posted @ 2025-10-08 19:35 黎恆 阅读(17) 评论(1) 推荐(0)