✔✔Simple JavaScript Solution✔✔
Approach\n Describe your approach to solving the problem. \nSimply we need to increment the counter as it call. If it is at \'n\', then in next call it will be 
# Approach\n<!-- Describe your approach to solving the problem. -->\nSimply we need to increment the counter as it call. If it is at \'n\', then in next call it will be \'n+1\'. So, postfix increment will the best, which give the original value first and then increment it by one.\n\n# Code\n```\n/**\n * @param {number} n\n * @return {Function} counter\n */\nvar createCounter = function(n) {\n    return function() {\n        return n++;\n    };\n};\n\n/** \n * const counter = createCounter(10)\n * counter() // 10\n * counter() // 11\n * counter() // 12\n */\n```
['JavaScript']