
c
qq_45911550
蚓无爪牙筋骨,唯用心也。
展开
-
模式识别
贝叶斯最小错误率决策(C实现) /* *Author:Lu Daze *Last modified time: Feb 4th, 2021 *Function: Bayesian minimum wrong decision */ #include<stdio.h> #include<stdlib.h> #include<math.h> int main() { // the number of classes int n_class;原创 2021-02-04 02:32:26 · 141 阅读 · 0 评论 -
c的动态数组构建
以三维为例 #include<stdio.h> #include<stdlib.h> int main() { int n1,n2,n3; printf("Enter n1, n2, n3 please! "); scanf("%d%d%d",&n1,&n2,&n3); int ***array; array=(int ***)calloc(n1,sizeof(int **)); for (int i=0;i&l原创 2021-02-03 23:52:04 · 78 阅读 · 0 评论 -
C语言程序简单编译运行
1.compile and run(if there is a file hello.c) //compile: gcc hello.c //run: ./a.out //if there are more than one file, using the following command: gcc test1.c test2.c -o main.out //run: ./main.out 2.debug c programmer //Compile: gcc -g test.c -o test //原创 2021-02-03 22:02:22 · 178 阅读 · 0 评论 -
第一章 c语言的探讨
1.1 C语言的编译链接和文件引用 编译链接 有代码如下:test.c int main(int argc,char *argv[]) { return argc; } 对于c 的目录组织方式: src:存放.c文件 obj:存放编译后的对象文件 inc:存放头文件 bin:存放可执行文件 //编译 gcc -c src/test.c -o obj/test.o //链接 gcc obj/test.o -o bin/test //执行 bin/test 1 3 //检测最近一步操作的返回 echo原创 2021-01-27 12:41:48 · 104 阅读 · 0 评论 -
C/C++定义常量的方法之一
#define LENGTH 10 const int LENGTH = 10; The two methods are equivalent.原创 2020-12-08 19:58:07 · 182 阅读 · 0 评论