摘要:
#include <iostream> using namespace std; //a b c float a*x^2+b*x+c=0 struct ReturnType { int type; vector<float> store; }; //multi-back vector<float> 阅读全文
摘要:
特殊的二分查找 普通的二分是在数组中查找元素,但这个是查找index。利用大小关系,快速排序的原理,C++中主要用到了swap交换元素,swap只有O(1)的复杂度,因为只需要交换内部的指针不需要遍历整个容器。 阅读全文
摘要:
use 3D version to calculate how much water the model can contain this problem need use dfs,from the edge part which mustn't be answer,for the edge can 阅读全文
摘要:
KMP need understand by step or will m 阅读全文
摘要:
1.question: find the longest length in the string has k types of characters 2.code attention a.length calculate need plus 1 i-left+1 b.if one characte 阅读全文