class Solution {#define SINGLE 1#define MULTIP 2public: bool isMatch(const char *s, const char *p) { if (s == NULL || p == NULL) return true...
分类:
其他好文 时间:
2014-09-14 01:20:56
阅读次数:
261
Suppose you have to evaluate an expression like A*B*C*D*E where A,B,C,D and E are matrices.Since matrix multiplication is associative, the order in which multiplications are performed isarbitrary. How...
分类:
其他好文 时间:
2014-09-13 09:26:28
阅读次数:
210
C++ 11 的lambda expression(简称LB),在可以保证和inline expression同样应能的条件下,增加了参数功能和闭包功能,是我们写出简洁,明了,以维护代码的绝佳工具。应用时,为了避免代码重复和增加隐身类的数量,可用有名无型的LB变量。LB也可以赋值于std::func...
分类:
编程语言 时间:
2014-09-13 06:12:14
阅读次数:
403
仅提供个人的一种解题思路,未必是最优,仅供各位参考!
import java.util.Stack;
/**
*
*
* ClassName SolutionEvaluateReversePolishNotation
*
*
* Description 该题是解逆波兰表达式 Evaluate the value of an arithmetic expression i...
分类:
其他好文 时间:
2014-09-11 22:29:42
阅读次数:
257
本系列作为Effective JavaScript的读书笔记。
所谓的即时调用的函数表达式,这个翻译也许不太准确,它对应的英文原文是Immediately Invoked Function Expression (IIFE)。下文也使用IIFE来表达这一概念。
首先看一个程序:
function wrapElements(a) {
var result = [], i,...
分类:
编程语言 时间:
2014-09-10 19:31:59
阅读次数:
211
Evaluate Reverse Polish NotationEvaluate the value of an arithmetic expression inReverse Polish Notation.Valid operators are+,-,*,/. Each operand may ...
分类:
其他好文 时间:
2014-09-10 14:09:30
阅读次数:
182
Evaluate the value of an arithmetic expression inReverse Polish Notation.Valid operators are+,-,*,/. Each operand may be an integer or another express...
分类:
编程语言 时间:
2014-09-10 05:07:09
阅读次数:
200
Implement regular expression matching with support for '.' and '*'.'.' Matches any single character.'*' Matches zero or more of the preceding element....
分类:
其他好文 时间:
2014-09-09 18:01:59
阅读次数:
146
Pointcut 是指那些方法需要被执行"AOP",是由"Pointcut Expression"来描述的.Pointcut可以有下列方式来定义或者通过&& || 和!的方式进行组合.args()@args()execution()this()target()@target()within()@wi...
分类:
其他好文 时间:
2014-09-09 15:36:58
阅读次数:
350
Regular Expression MatchingProblem description:Implement regular expression matching with support for'.'and'*'.'.' Matches any single character.'*' Ma...
分类:
其他好文 时间:
2014-09-09 11:37:58
阅读次数:
281