My code seems to give the correct result but I still get the following error:
My helper.js file:
export const hasUpperCaseLetters = (s) => {
//const uCase = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
for (let i = 0; i < s.length; i++) {
//if ((uCase.includes(s[i]) === true)) {
if (s[i] >= 'A' && s[i] <= 'Z') {
return true;
}
}
return false;
}
Please let me know what am I doing wrong.