会员
周边
新闻
博问
AI培训
云市场
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
黑卡卡卡蒂
博客园
首页
新随笔
联系
订阅
管理
2020年12月30日
实验7 文件
摘要: 实验任务3 基于运行观察,回答实验任务3中的问题: 运行程序,观察在屏幕上是否正确输出了按分数由高→低排序的信息? 是的。 同时,在当前路径下,是否生成了文本文件file3.dat? 是的。 尝试用记事本程序打开文件file3.dat,观察里面的数据信息是否是正确的,并且是直观可读的? 非常直观可读
阅读全文
posted @ 2020-12-30 20:38 黑卡卡卡蒂
阅读(66)
评论(1)
推荐(0)
编辑
2020年12月23日
实验6 结构体
摘要: 实验任务1 1 #include<stdio.h> 2 #include<stdlib.h> 3 #include<string.h> 4 #define N 3 5 6 typedef struct student { 7 int id; 8 char name[20]; 9 char subje
阅读全文
posted @ 2020-12-23 20:25 黑卡卡卡蒂
阅读(92)
评论(2)
推荐(0)
编辑
2020年12月16日
实验5 数组和函数
摘要: 实验任务1 1 #include <stdio.h> 2 3 const int N=3; 4 int main() { 5 int a[N] = {1, 2, 3}; 6 int i; 7 8 printf("通过数组名及下标直接访问数组元素:\n"); 9 for(i=0; i<N; i++)
阅读全文
posted @ 2020-12-16 22:04 黑卡卡卡蒂
阅读(109)
评论(1)
推荐(0)
编辑
2020年12月2日
实验4 函数和数组
摘要: 实验任务1 结论 不能,返回值有两个,不方便如此设计。 实验任务2 1 #include <stdio.h> 2 long long fac(int); 3 main() 4 { 5 int i,n; 6 printf("Enter n:"); 7 scanf("%d",&n); 8 for(i =
阅读全文
posted @ 2020-12-02 20:39 黑卡卡卡蒂
阅读(58)
评论(1)
推荐(0)
编辑
2020年11月19日
实验3 C语言分支语句和循环语句变成应用
摘要: 实验任务1 1 #include <math.h> 2 #include <stdio.h> 3 int main() 4 { 5 float a, b, c, x1, x2; 6 float delta, real, imag; 7 printf("Enter a, b, c: "); 8 whi
阅读全文
posted @ 2020-11-19 14:02 黑卡卡卡蒂
阅读(102)
评论(1)
推荐(0)
编辑
2020年11月3日
实验2 C语言表达式编辑应用及输入输出函数
摘要: 实验1 #include <stdio.h> int main () { int a = 5, b = 7, c =100, d, e, f; d = a/b*c; e = a*c/b; f = c/b*a; printf("d=%d,e=%d,f=%d\n",d,e,f); return 0; }
阅读全文
posted @ 2020-11-03 21:50 黑卡卡卡蒂
阅读(159)
评论(2)
推荐(0)
编辑
2020年10月16日
实验1 C语言开发环境使用和编程初体验
摘要: 实验任务1——helloC.cpp # include <stdio.h> int main() { printf("202083450025\n"); printf("2020,I'll be fine."); return 0; } 实验任务2——printChar.cpp #include <
阅读全文
posted @ 2020-10-16 21:09 黑卡卡卡蒂
阅读(80)
评论(1)
推荐(0)
编辑