leetcode
文章平均质量分 73
Kking2king
我的心愿是。。。
世界和平!
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
问题 H: B C++时间类的运算符重载
题目描述 C++时间类的运算符重载 定义一个时间类Time,其数据成员为表示时间的小时(hour)、分(minute),秒(second)。 重载运算符“+”,使之能用于时间对象的加法运算;重载运算符“<<”,使之能用于时间对象的输出操作。 (1)参加运算的两个操作数可以都是时间类对象,也可以其中有一个是整数(表示秒),顺序任意。 例如,t1+t2,i+t1,t1+i均合法(设i为整数表示原创 2017-10-27 14:35:48 · 696 阅读 · 0 评论 -
手算KMP匹配的Next值与Nextvul值
文章作者:姜南(Slyar) 文章来源:Slyar Home (www.slyar.com)KMP 算法我们有写好的函数帮我们计算 Next 数组的值和 Nextval 数组的值,但是如果是考试,那就只能自己来手算这两个数组了,这里分享一下我的计算方法吧。计算前缀 Next[i] 的值:我们令 next[0] = -1 。从 next[1] 开始,每求一个字符的 next 值,就看它前面是否有一个最转载 2017-10-29 22:40:25 · 495 阅读 · 0 评论 -
LeetCode 2 Add Two Number
You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it原创 2017-10-16 20:07:05 · 311 阅读 · 0 评论 -
LeetCode3 Longest Substring Without Repeating Characters
Given a string, find the length of the longest substring without repeating characters.Examples:Given “abcabcbb”, the answer is “abc”, which the length is 3.Given “bbbbb”, the answer is “b”, with the le原创 2017-10-16 21:22:16 · 251 阅读 · 0 评论
分享