Simple JS Solution using substring
\n/**\n * @param {string} s\n * @param {number} k\n * @return {string}\n */\nvar reverseStr = function(s, k) {\n    if (k > s.length)\n        return s.split(\'
```\n/**\n * @param {string} s\n * @param {number} k\n * @return {string}\n */\nvar reverseStr = function(s, k) {\n    if (k > s.length)\n        return s.split(\'\').reverse().join(\'\');\n    for (let i = 0; i < s.length; i += 2 * k) {\n        s = s.substring(0, i) + s.substr(i, k).split(\'\').reverse().join(\'\') + s.substring(i + k);\n    }\n    return s;\n};\n\n```
['String', 'JavaScript']