Easy Javascript Solution
```\nvar calPoints = function(ops) {\n    let stack = [];\n    for(let i=0; ia+b);\n};
```\nvar calPoints = function(ops) {\n    let stack = [];\n    for(let i=0; i<ops.length; i++){\n    if(ops[i] == \'D\'){\n        stack.push(2 * stack.slice(-1)[0]);\n    }else if(ops[i] === \'C\'){\n         stack.pop();\n    }else if(ops[i] === \'+\'){\n        stack.push(stack.slice(-1)[0] + stack.slice(-2)[0])\n     }else{\n         stack.push(parseInt(ops[i]));\n     }\n        \n    }\n    return stack.reduce((a,b)=>a+b);\n};
['Stack', 'JavaScript']