Javascript Solution || Simple & Understandable || Fast
\nvar greatestLetter = function(s) {\n    let alphebet = \'aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ\'\n    let result;\n    for (let letter of s) {\
```\nvar greatestLetter = function(s) {\n    let alphebet = \'aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ\'\n    let result;\n    for (let letter of s) {\n        if (alphebet.indexOf(letter) > alphebet.indexOf(result)) {\n            let upper = letter.toUpperCase()\n            if (s.includes(upper) && s.includes(letter.toLowerCase())) result = upper;\n        }\n    } if (!result) return "";\n    return result;\n};\n```\n\n![image](https://assets.leetcode.com/users/images/3d8192cb-6239-4e40-9094-ed1c5a98cd7a_1655662629.7124755.png)\n
['JavaScript']