Skip to content

Commit f57c275

Browse files
authored
Update solution.hide.js
1 parent 63bebeb commit f57c275

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

exercises/156-isogram/solution.hide.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
function isIsogram(text) {
22
// your code here
3+
let lowerCaseText = text.toLowerCase()
4+
35
const chars = {};
4-
for (const char of text) {
6+
for (const char of lowerCaseText) {
57
chars[char] = (chars[char] || 0) + 1;
68
}
79
let result = Object.entries(chars)

0 commit comments

Comments
 (0)