摘要: 一,介绍RazorGenerator的安装方式 1在vs-tool-拓展和更新,找到razor generator并安装 2 以图2-1为例,在建立的Module_X工程中,将对应的cshtml应用zazorgenerator工具(图2-2),结果应如图2-3所示 图2-1 图2-2 图2-3 二, 阅读全文
posted @ 2016-10-23 12:25 朽木可雕否 阅读(2122) 评论(0) 推荐(0) 编辑
摘要: controller都继承于自定义的一个controller的基类,在此基类上实施切片操作。 namespace mv13.Controllers{ public class LoginController : Controller { // // GET: /Login/ public strin 阅读全文
posted @ 2016-07-06 21:00 朽木可雕否 阅读(171) 评论(0) 推荐(0) 编辑
摘要: 理解了一下stl的空间配置器,发现一个比较好的学习方法,跟着代码自己也跟着写一遍,顺便加些注释,可以更加帮助自己理解。如new,delete一般,分为两个步骤,1,配置空间,2,构造对象(1,析构对象,2,释放空间)一。构造和析构的基本工具(construct,destroy)1,construct... 阅读全文
posted @ 2015-08-16 20:14 朽木可雕否 阅读(368) 评论(0) 推荐(1) 编辑
摘要: 在看陈硕的Linux多线程服务器编程时 ,看到生成全排列的一种方式,使用stl的next_permutation方法,正好手上有本stl源码剖析,就研究了下这个算法。templatebool next_permutation( BidirectionalIterator first, ... 阅读全文
posted @ 2015-08-14 20:59 朽木可雕否 阅读(288) 评论(0) 推荐(0) 编辑
摘要: 传说中的 看毛片算法~~~,嘿嘿嘿推荐博客,讲的很好http://www.ruanyifeng.com/blog/2013/05/Knuth%E2%80%93Morris%E2%80%93Pratt_algorithm.htmlhttp://www.cnblogs.com/10jschen/arch... 阅读全文
posted @ 2015-08-06 14:46 朽木可雕否 阅读(145) 评论(0) 推荐(0) 编辑
摘要: 回溯法理解,一般形式void Bcktrack(int t) //参数t表示当前递归深度{ if(t>n)Output(x); //遍历到解,则将解输出或其他处理 else { //f(n,t)和g(n,t)表示当前节点(扩展节点)处未搜索过的子树的起始编号和中指编号... 阅读全文
posted @ 2015-08-06 14:14 朽木可雕否 阅读(1764) 评论(0) 推荐(0) 编辑
摘要: 使用快速排序,从数组中随机找出一个元素X,把数组分成比X小和比X大的两部分,假设比X小的部分元素个数为B,则: (1)如果B >= K,则递归从比X小的部分找第K大的元素。 (2)如果B & v,int begin,int end,int index){ int lchild =... 阅读全文
posted @ 2015-08-05 16:14 朽木可雕否 阅读(320) 评论(0) 推荐(0) 编辑
摘要: 头文件/************************* 交换排序**************************///冒泡排序void BubbleSort(vector &v,int begin,int end);//快速排序void QuickSort(vector & v... 阅读全文
posted @ 2015-07-27 16:13 朽木可雕否 阅读(176) 评论(0) 推荐(0) 编辑
摘要: 函数配接器bind1st(op,value) ----> op(value,param) //绑定op的第一个参数bind2st(op,value) ----> op(param,value)not1(op) ---->!op(param)not2(op) ---->!op(param1,par... 阅读全文
posted @ 2015-07-19 20:28 朽木可雕否 阅读(193) 评论(0) 推荐(0) 编辑
摘要: templatestruct Compare{ bool operator()(const T & ele1,const T &ele2){ return ele1 #include #include #include using namespace std;templatest... 阅读全文
posted @ 2015-07-19 18:59 朽木可雕否 阅读(155) 评论(0) 推荐(0) 编辑