MinStack JavaScript solution
/**\n     * @constructor\n     */\n    var MinStack = function() {\n        this.minStack = [];\n        this.container = [];\n    };\n    \n    /**\n     * @pa
    /**\n     * @constructor\n     */\n    var MinStack = function() {\n        this.minStack = [];\n        this.container = [];\n    };\n    \n    /**\n     * @param {number} x\n     * @returns {void}\n     */\n    MinStack.prototype.push = function(x) {\n        this.container.push(x);\n        if (this.minStack.length === 0 || x <= this.minStack[this.minStack.length - 1]) {\n            this.minStack.push(x);\n        }\n    };\n    \n    /**\n     * @returns {void}\n     */\n    MinStack.prototype.pop = function() {\n        var x = this.container.pop();\n        if (x === this.minStack[this.minStack.length - 1]) {\n            this.minStack.pop();\n        }\n    };\n    \n    /**\n     * @returns {number}\n     */\n    MinStack.prototype.top = function() {\n        return this.container[this.container.length - 1];\n    };\n    \n    MinStack.prototype.getMin = function() {\n        return this.minStack[this.minStack.length - 1];\n    }
['JavaScript']