摘要:
#include<stdio.h> #include<stdlib.h> #define N 10 typedef struct student { int num; char name[20]; int score; } STU; void sort(STU *pst, int n); int m 阅读全文
摘要:
#include<stdio.h> #include<stdlib.h> #include<string.h> #define N 3 typedef struct student { int id; //学号 char name[20]; //姓名 char subject[20]; float 阅读全文
摘要:
#include<stdio.h> const int N=3; int main(void) { int a[N]={1,2,3}; int i=0; printf("通过数组名及下标直接访问数组元素:\n"); for(i=0; i<N; i++) printf("%d: %d\n",&a[i] 阅读全文
摘要:
// 一元二次方程求解(函数实现方式) // 重复执行, 直到按下Ctrl+Z结束 #include<stdio.h> #include<math.h> void solve(double,double,double); int main() { double a,b,c; printf("Ente 阅读全文
摘要:
#include <math.h> #include <stdio.h> int main() { float a,b,c,x1,x2; float delta, real, imag; printf("Enter a, b, c: "); while(scanf("%f %f %f", &a, & 阅读全文
摘要:
// ex1.cpp #include <stdio.h> int main() { int a=5, b=7, c=100, d, e, f; d = a/b*c, //d=(a与b的取整商)*c e = a*c/b, //e=(a*c)与b的取整商 f = c/b*a; //f=(c与b的取整商 阅读全文
摘要:
/*A simple C program*/ #include <stdio.h> int main() { printf("My stuno is: 202083450026\n"); printf("2020,r u crazy\n"); return 0; } /*循环打印字符*/ #incl 阅读全文