qingcheng奕  

2014年8月17日

摘要: https://oj.leetcode.com/problems/valid-number/判断给的串,是不是合理的 数字形式主要问题在需求定义上吧class Solution {public: bool isNumber(const char *s) { if(s == NUL... 阅读全文
posted @ 2014-08-17 20:29 qingcheng奕 阅读(135) 评论(0) 推荐(0) 编辑
 
摘要: https://oj.leetcode.com/problems/wildcard-matching/模拟通配符的匹配做法非常好 class Solution {public: bool isMatch(const char *s, const char *p) { bool h... 阅读全文
posted @ 2014-08-17 17:25 qingcheng奕 阅读(123) 评论(0) 推荐(0) 编辑
 
摘要: https://oj.leetcode.com/problems/string-to-integer-atoi/细节题,把一个字符串转换成整数class Solution {public: int atoi(const char *str) { if(str == NULL) ... 阅读全文
posted @ 2014-08-17 14:49 qingcheng奕 阅读(120) 评论(0) 推荐(0) 编辑
 
摘要: https://oj.leetcode.com/problems/minimum-window-substring/模拟题这道题细节比较多。从左到右扫一遍模拟着做 class Solution {public: string minWindow(string S, string T) { ... 阅读全文
posted @ 2014-08-17 11:37 qingcheng奕 阅读(154) 评论(0) 推荐(0) 编辑