汇编相关

摘要: 寄存器 汇编指令 push_*_ 压栈 (l:16位,q:32位) pop_*_ 弹栈 (l:16位,q:32位) mov_*_(from,to) 移动 * 位的数据 (l:16位,q:32位) call 调用函数 ret 返回 lea_*_(from,to) 将from的地址加载到to中 (l:1 阅读全文
posted @ 2021-02-20 23:19 平ping 阅读(60) 评论(0) 推荐(0)

七大排序——C实现

摘要: #include<stdio.h> #include<stdlib.h> #include<string.h> #include<time.h> #define MAX_NUM_SIZE 20000000 #define MAX_RANDOM_NUM 100 #define SWAP(a,b){in 阅读全文
posted @ 2021-02-16 21:50 平ping 阅读(59) 评论(0) 推荐(0)

C语言——txt词频统计

摘要: 1 #define _CRT_SECURE_NO_WARNINGS 2 #include<stdio.h> 3 #include<stdlib.h> 4 #include<string.h> 5 #define MAXKEY 2000 6 #define MAX_WORD_SIZE 30 7 8 i 阅读全文
posted @ 2021-02-09 18:02 平ping 阅读(304) 评论(0) 推荐(0)

C——qsort()排序指针数组的概括用法

摘要: qsort( 【* 指针,解引用后指向的是 等待排序的元素的类型 的指针数组 】,【count,数组中的指针解引用后的元素的数量】,【size,数组中的指针解引用后的元素的大小】 ,compare 【compare是回调函数,没有()】) int compare(const void *p1,con 阅读全文
posted @ 2021-02-06 21:41 平ping 阅读(266) 评论(0) 推荐(0)

C——数组元素的二叉树创建

摘要: 1 int main() { 2 char c[] = "ABCDEFGHIJ"; 3 pTreeNode_t pArr[MAX_SIZE_OF_TREE]; 4 for (int i = 0; i < MAX_SIZE_OF_TREE; i++) { 5 pArr[i] = (pTreeNode_ 阅读全文
posted @ 2021-02-03 23:58 平ping 阅读(177) 评论(0) 推荐(0)

C语言链表——头插法和尾插法

摘要: #define _CRT_SECURE_NO_WARNINGS #include<stdio.h> #include<stdlib.h> typedef struct ListNode{ int val; ListNode* next; }Node_t, *pNode_t; void print_l 阅读全文
posted @ 2021-02-02 20:59 平ping 阅读(447) 评论(0) 推荐(0)

C语言——创建动态二维数组

摘要: int main() { int **a; int row, column; int count = 0; scanf("%d%d", &row, &column); a = (int **)malloc(row * sizeof(int *)); for (int i = 0; i < row; 阅读全文
posted @ 2021-02-01 21:05 平ping 阅读(489) 评论(0) 推荐(0)

c笔记——指针错误情况

摘要: 指针错误情况: 1、空指针 指向不可访问的地址: { int *p; *p = 1; } 2、野指针 指向未分配空间的地址: { int *p; p = NULL; *p = 1; } 指向未知的特定地址 { char *p = 0x00123456; *p = 1; } 3、悬空指针 使用了已经f 阅读全文
posted @ 2021-01-30 22:48 平ping 阅读(228) 评论(0) 推荐(0)

输入年,输出一整年的日历

摘要: 输入年,输出一整年的日历 #define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include<math.h> int Year_return, Month_return, Days_return; //date_after_days()的传出参数 阅读全文
posted @ 2021-01-29 19:49 平ping 阅读(285) 评论(0) 推荐(0)

Leetcode 739. 每日温度 ——栈

摘要: 请根据每日 气温 列表,重新生成一个列表。对应位置的输出为:要想观测到更高的气温,至少需要等待的天数。如果气温在这之后都不会升高,请在该位置用 0 来代替。 例如,给定一个列表 temperatures = [73, 74, 75, 71, 69, 72, 76, 73],你的输出应该是 [1, 1 阅读全文
posted @ 2021-01-27 17:40 平ping 阅读(56) 评论(0) 推荐(0)