/*二分查找 */ #include<stdio.h>int binarySearch(int a[],int n,int key){ int left=0; int right=n-1; while(left<=right){ int middle=(left+right)/2; if(a[mid ...
分类:
编程语言 时间:
2019-12-20 01:24:21
阅读次数:
218
复现链接:https://ac.nowcoder.com/acm/contest/3405#question shzr题解:https://www.cnblogs.com/shzr/p/12018915.html echozhou题解:https://www.cnblogs.com/EchoZQN/ ...
分类:
其他好文 时间:
2019-12-20 00:57:25
阅读次数:
86
实验要求: Socket API编程接口之上可以编写基于不同网络协议的应用程序; Socket接口在用户态通过系统调用机制进入内核; 内核中将系统调用作为一个特殊的中断来处理,以socket相关系统调用为例进行分析; socket相关系统调用的内核处理函数内部通过“多态机制”对不同的网络协议进行的封 ...
分类:
其他好文 时间:
2019-12-19 23:44:51
阅读次数:
156
在头文件中有 #define OB_RDP_LEVEL_1 ((uint8_t)0x55) 代码中也调用了 HAL_FLASHEx_OBProgram(&OptionsBytesStruct) 然后就变成0x55了,代码读保护了。 用STM32CubeProgrammer把熔丝改回AA,用ST Li ...
分类:
其他好文 时间:
2019-12-19 21:13:44
阅读次数:
182
学生成绩管理系统 #include<stdio.h>#include<stdlib.h>//颜色#include<conio.h>//清屏#include<string.h>#define LEN sizeof(struct student)#define SDJ stu[s].ID,stu[s]. ...
分类:
编程语言 时间:
2019-12-18 22:05:52
阅读次数:
120
二叉排序树统计字符串 结点的类型: 完整代码 ...
分类:
编程语言 时间:
2019-12-18 20:18:27
阅读次数:
157
利用 Object.prototype.toString 判断数据类型 普通的判断方式有各种不足,typeof就不说了,判断模糊 constructor这种判断方式是可以,但是也有不足,如果aaa为null或者undefined的时候,代码就会报错 var aaa = {} aaa.construc ...
分类:
编程语言 时间:
2019-12-18 12:53:46
阅读次数:
95
安装: pip install mitmproxy 新建一个脚本 脚本代码: 1 from mitmproxy import ctx 2 3 injected_javascript = ''' 4 // overwrite the `languages` property to use a cust ...
分类:
Web程序 时间:
2019-12-18 12:36:17
阅读次数:
282
https://www.luogu.com.cn/problem/P4168 题目 给$n$个数字,有$m$次询问,问$a_l, a_{l+1} , \dots , a_r$的众数是什么, $1\leqslant n \leqslant 40000, 1\leqslant m \leqslant 5 ...
分类:
其他好文 时间:
2019-12-17 22:08:19
阅读次数:
88
"题意" 显然是贪心。 先建出SAM,之后能走相同的字符就走相同的字符,实在不行再走一个比它大的。 考虑怎么处理$[l,r]$的限制,我们只要用线段树合并维护出每个点的endpos集合,到时候判断下走这一步是否合法即可。 code: ...
分类:
其他好文 时间:
2019-12-17 20:23:15
阅读次数:
100