/*字符串匹配*/
#include
using namespace std;
void get_next(string T,int *next)
{//朴素算法
int i,j;
i=1;
j=0;
next[1]=0;
while(i<T.length())
{
if(j==0 || T[i]==T[j])
{
i++;
j++;
next[i]=j;
...
分类:
编程语言 时间:
2015-07-01 18:22:16
阅读次数:
140
代码: 1 #include 2 #include 3 4 using namespace std; 5 6 struct ListNode { 7 int val; 8 ListNode *next; 9 ListNode(int x) : val(x), ne...
分类:
其他好文 时间:
2015-07-01 18:00:08
阅读次数:
84
一、AutoMapper初探:[参考Using AutoMapper: Getting Started]1.新建空的ASP.NET MVC项目。2.在Models文件夹添加类: public class Book { public string Title { get; s...
分类:
移动开发 时间:
2015-07-01 17:43:37
阅读次数:
328
Your Diesel engine Designer watches and buying Diesel engine Designer watches can be purchased on-line using a number of internet sites as well as fir...
分类:
其他好文 时间:
2015-07-01 17:43:26
阅读次数:
143
using UnityEngine;using System.Collections; public class PageView : MonoBehaviour{ const int ITEM_NUM = 2; //总页数 const int PAGE_WIDTH =...
分类:
其他好文 时间:
2015-07-01 17:34:03
阅读次数:
241
1. Trace & Debug理解这两者的区别,Trace有个Listners.Add()非常好用,这里网上有个在ListBox里输出Debug和Trace信息的 1 using System; 2 using System.Collections.Generic; 3 using System....
代码: 1 #include 2 #include 3 4 using namespace std; 5 6 vector spiralOrder(vector>& matrix) 7 { 8 if (matrix.size() == 0) 9 return vector...
分类:
其他好文 时间:
2015-07-01 17:23:19
阅读次数:
135
using UnityEngine;using System.Collections;public class UDragManager : MonoBehaviour { public Transform target; private Vector3 offset; p...
分类:
其他好文 时间:
2015-07-01 17:21:29
阅读次数:
100
#include
using namespace std;
//实现一个函数求字符串的长度。
int my_length(const char *s)
{
if (*s == '\0')return 0;
else
return 1+my_length(s + 1);
}
int main()
{
char *s = "123456";...
分类:
编程语言 时间:
2015-07-01 16:05:21
阅读次数:
211
using UnityEngine; using System.Collections;public class moster_AI : MonoBehaviour {public const int AI_Null = 10; public const int AI_Idle = 0; publi...
分类:
编程语言 时间:
2015-07-01 15:48:56
阅读次数:
206