CraigZeng
CraigZeng
When i set [mousetrap] classname in the target react node, the real target may still not has class mousetrap
``` javascript function pascal(depth) { var result = [[1],[1, 1]]; if(depth==1){ return result.splice(0,1)}; if(depth==2){ return result}; for(var i = 2 ; i< depth; i++){ result[i] = [1]; result[i-1].reduce(function(prev, current){result[i].push(prev+current);return current;});...
@Justhin 效率还可以啊100W 70ms
``` javascript function solution(digits){ var result = []; (digits+'').replace(/\d(?=\d{4})/g, function(match, pos, str){ result.push(+str.substr(pos, 5)); }); return Math.max.apply(null, result); } ```
``` String.prototype.reverse = function(){ return Array.prototype.slice.call(this).reverse().join(''); } ```