摘要: class Solution { public: string toHexspeak(string num) { stringstream ss; long long inter; //转16进制 string hexret; ss << num; ss >> inter; ss.clear(); 阅读全文
posted @ 2020-01-09 21:54 chiwin 阅读(256) 评论(0) 推荐(0) 编辑
摘要: 为什么三次握手: 让服务端和客户端都知道,自己的收信能力和发信能力没有问题; 第一次:客户端发给服务端--服务端知道了,自己的收信能力和客户端的发信能力没有问题; 第二次:服务端回复客户端--客户端知道了,自己的发信能力和收信能力没有问题,不然不会收到服务端的回信;服务端发信能力和收信能力没问题,不 阅读全文
posted @ 2020-01-03 16:44 chiwin 阅读(96) 评论(0) 推荐(0) 编辑
摘要: 符号类型 说明 A 该符号的值是绝对的,在以后的链接过程中,不允许进行改变。这样的符号值,常常出现在中断向量表中,例如用符号来表示各个中断向量函数在中断向量表中的位置。 B 该符号的值出现在非初始化数据段(bss)中。例如,在一个文件中定义全局static int test。则该符号test的类型为 阅读全文
posted @ 2020-01-03 14:40 chiwin 阅读(318) 评论(0) 推荐(0) 编辑
摘要: /** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */ class Solu 阅读全文
posted @ 2020-01-02 22:12 chiwin 阅读(94) 评论(0) 推荐(0) 编辑
摘要: class Solution { public: string gethead(string str){//获取头单词 string ret = ""; int strlen = str.length(); for(int i = 0; i < strlen; ++i){ if(str[i] == 阅读全文
posted @ 2020-01-02 20:42 chiwin 阅读(255) 评论(0) 推荐(0) 编辑
摘要: C++: class Solution { public: int missingNumber(vector<int>& arr) { int subnum = abs(arr[1]-arr[0]) < abs(arr[2]-arr[1]) ? arr[1]-arr[0] : arr[2]-arr[ 阅读全文
posted @ 2020-01-02 17:38 chiwin 阅读(282) 评论(0) 推荐(0) 编辑
摘要: 一、有个基础镜像 1.基础镜像的选择 当前市场有众多可选择的基础docker镜像,可参考: https://blog.csdn.net/nklinsirui/article/details/80967677 2.下载基础镜像 下载下来后将镜像传到linux环境上 3.载入基础镜像 docker lo 阅读全文
posted @ 2019-12-19 15:21 chiwin 阅读(630) 评论(0) 推荐(0) 编辑
摘要: 一、可变宏 1.# 可以接收一个参数,并把这个参数按照原来的字符串源码原样传给宏内部; 1 #define RR(x) printf(#x"\n"); 2 int main(){ 3 int a = 1; 4 RR(1); 5 RR(a); 6 return 0; 7 } 输出: 1 a 解释:#x 阅读全文
posted @ 2019-12-04 19:43 chiwin 阅读(257) 评论(0) 推荐(0) 编辑
摘要: https://blog.csdn.net/u012308586/article/details/95746745 阅读全文
posted @ 2019-12-04 10:45 chiwin 阅读(107) 评论(0) 推荐(0) 编辑
摘要: 一、cofigure是怎么生成的,我们又是怎么使用的 configure和make install背后的故事: https://azyet.github.io/2015/06/20/configureAndMakeInstall/ 二、cmake怎么用的 2.1 cmake参考材料 cmake入门: 阅读全文
posted @ 2019-11-29 09:51 chiwin 阅读(211) 评论(0) 推荐(0) 编辑