摘要: 10.2文件的打开和关闭 10.2.1 文件指针 在C语言中用一个指针变量指向一个文件,这个指针称为文件指针。 点击查看代码 typedef struct { short level; //缓冲区"满"或者"空"的程度 unsigned flags; //文件状态标志 char fd; //文件描述 阅读全文
posted @ 2023-02-09 23:49 nullptrException 阅读(81) 评论(0) 推荐(0) 编辑
摘要: 实验任务 使用Pthreads库创建多个线程,并观察线程的并发执行现象以及数据共享关系 Monte Carlo技术计算Π值(多线程): Π = 4 * (圆内点数)/ (总的点数) 1.随机的生成一个点Random(x,y), 2.如果这个点在圆内,就用一个变量把它记下来circle_point++ 阅读全文
posted @ 2023-02-09 23:01 nullptrException 阅读(9) 评论(0) 推荐(0) 编辑
摘要: 24.四数之和 阅读全文
posted @ 2023-02-09 22:54 nullptrException 阅读(11) 评论(0) 推荐(0) 编辑
摘要: 23.三数之和 阅读全文
posted @ 2023-02-09 22:53 nullptrException 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 22.搜索插入位置 阅读全文
posted @ 2023-02-09 22:53 nullptrException 阅读(5) 评论(0) 推荐(0) 编辑
摘要: 21.按奇偶排序数组|| 阅读全文
posted @ 2023-02-09 22:53 nullptrException 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 20.寻找数组的中心索引 阅读全文
posted @ 2023-02-09 22:52 nullptrException 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 19.旋转数组 阅读全文
posted @ 2023-02-09 22:52 nullptrException 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 18.独一无二的出现次数 阅读全文
posted @ 2023-02-09 22:52 nullptrException 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 17.有效的山脉数组 阅读全文
posted @ 2023-02-09 22:52 nullptrException 阅读(2) 评论(0) 推荐(0) 编辑
摘要: 16.有多少小于当前数字的数字 阅读全文
posted @ 2023-02-09 22:51 nullptrException 阅读(11) 评论(0) 推荐(0) 编辑
摘要: 15.顺时针打印矩阵 阅读全文
posted @ 2023-02-09 22:51 nullptrException 阅读(5) 评论(0) 推荐(0) 编辑
摘要: 14.螺旋矩阵 阅读全文
posted @ 2023-02-09 22:51 nullptrException 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 13.最小覆盖字串 阅读全文
posted @ 2023-02-09 22:50 nullptrException 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 12.水果成篮 阅读全文
posted @ 2023-02-09 22:50 nullptrException 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 11.长度最小的子数组 阅读全文
posted @ 2023-02-09 22:34 nullptrException 阅读(1) 评论(0) 推荐(0) 编辑
摘要: #ifndef __SYLAR_LOG_H__ #define __SYLAR_LOG_H__ #include<iostream> #include<string> #include<stdint.h>//为了使用int32_t #include<memory>//为了使用shared_ptr # 阅读全文
posted @ 2023-02-09 22:27 nullptrException 阅读(57) 评论(0) 推荐(0) 编辑
摘要: 10.有序数组的平方 阅读全文
posted @ 2023-02-09 22:18 nullptrException 阅读(5) 评论(0) 推荐(0) 编辑
摘要: 第二章:如何保证服务程序用不停机 阅读全文
posted @ 2023-02-09 22:16 nullptrException 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 9.比较含退格的字符串 阅读全文
posted @ 2023-02-09 20:21 nullptrException 阅读(7) 评论(0) 推荐(0) 编辑