JS || Soution by Bharadwaj
Intuition\nfunction modifyString(s) {\n  // Array of lowercase letters for replacement\n  const letters = [\'a\', \'b\', ..., \'z\'];\n\n  // Iterate through ea
# Intuition\nfunction modifyString(s) {\n  // Array of lowercase letters for replacement\n  const letters = [\'a\', \'b\', ..., \'z\'];\n\n  // Iterate through each character in the string\n  for (let i = 0; i < s.length; i++) {\n    // If the character is \'?\', replace it with a distinct letter\n    if (s[i] === \'?\') {\n      s = s.replace(\n        s[i],\n        // Find a letter that\'s different from adjacent characters\n        letters.find((el) => el !== s[i - 1] && el !== s[i + 1])\n      );\n    }\n  }\n  // Return the modified string\n  return s;\n}\n\n\n# Code\n```\nvar modifyString = function (s) {\n    const a = [\n        \'a\', \'b\', \'c\', \'d\', \'e\', \'f\', \'g\', \'h\', \'i\', \'j\', \'k\', \'l\', \'m\', \'n\', \'o\', \'p\', \'q\', \'r\', \'s\', \'t\', \'u\', \'v\', \'w\', \'x\', \'y\', \'z\',\n    ];\n    for (let i = 0; i < s.length; i++) {\n        if (s[i] === \'?\') {\n            s = s.replace(\n                s[i],\n                a.find(el => el !== s[i - 1] && el !== s[i + 1]),\n            );\n        }\n    }\n    return s;\n};\n```
['JavaScript']