As easy as "abc"
js\nconst convertChar = (arr, i) => {\n  if (arr[i] !== \'?\') {\n    return arr[i]\n  }\n\n  if (arr[i - 1] !== \'a\' && arr[i + 1] !== \'a\') {\n    return \'
```js\nconst convertChar = (arr, i) => {\n  if (arr[i] !== \'?\') {\n    return arr[i]\n  }\n\n  if (arr[i - 1] !== \'a\' && arr[i + 1] !== \'a\') {\n    return \'a\'\n  }\n\n  if (arr[i - 1] !== \'b\' && arr[i + 1] !== \'b\') {\n    return \'b\'\n  }\n\n  return \'c\'\n}\n\n/**\n * @param {string} s\n * @return {string}\n */\nconst modifyString = function (s) {\n  const arr = s.split(\'\')\n\n  for (let i = 0; i < s.length; i++) {\n    arr[i] = convertChar(arr, i)\n  }\n\n  return arr.join(\'\')\n}\n\nmodule.exports = modifyString\n```\n\n---\n\nSee more of my LeetCode JavaScript solutions with 100% code coverage tests: https://github.com/ecgan/leetcode
['JavaScript']