12 2020 档案

摘要:#include<stdio.h> #include<stdlib.h> #include<string.h> #define N 3 // 运行程序输入测试时,可以把N改小一些输入测试 typedef struct student { int id; /*学生学号 */ char name[20] 阅读全文
posted @ 2020-12-25 12:26 行客自多愁丶 阅读(77) 评论(0) 推荐(0)
摘要:#include <stdio.h> const int N=3; int main() { int a[N] = {1, 2, 3}; int i; printf("通过数组名及下标直接访问数组元素:\n"); for(i=0; i<N; i++) printf("%d: %d\n", &a[i] 阅读全文
posted @ 2020-12-18 12:56 行客自多愁丶 阅读(97) 评论(0) 推荐(0)
摘要:实验一 return 只能返回一个值,故无法实现一元二次方程两个根的返回 实验二 2.1 // 利用局部static变量计算阶乘 #include <stdio.h> long long fac(int n); // 函数声明 int main() { int i,n; printf("Enter 阅读全文
posted @ 2020-12-03 23:43 行客自多愁丶 阅读(95) 评论(0) 推荐(0)