File tree 1 file changed +5
-3
lines changed
1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -38,9 +38,9 @@ def check_pangram_faster(
38
38
"""
39
39
>>> check_pangram_faster("The quick brown fox jumps over the lazy dog")
40
40
True
41
- >>> check_pangram ("Waltz, bad nymph, for quick jigs vex.")
41
+ >>> check_pangram_faster ("Waltz, bad nymph, for quick jigs vex.")
42
42
True
43
- >>> check_pangram ("Jived fox nymph grabs quick waltz.")
43
+ >>> check_pangram_faster ("Jived fox nymph grabs quick waltz.")
44
44
True
45
45
>>> check_pangram_faster("The quick brown fox jumps over the la_y dog")
46
46
False
@@ -50,7 +50,9 @@ def check_pangram_faster(
50
50
flag = [False ] * 26
51
51
for char in input_str :
52
52
if char .islower ():
53
- flag [ord (char ) - ord ("a" )] = True
53
+ flag [ord (char ) - 97 ] = True
54
+ elif char .isupper ():
55
+ flag [ord (char ) - 65 ] = True
54
56
return all (flag )
55
57
56
58
You can’t perform that action at this time.
0 commit comments