

0 / 2 embers
0 / 3000 xp
click for more info
Complete a lesson to start your streak
click for more info
Still calibrating
click for more info
Not enough gems
Cost: 6 gems
1: Running Python
incomplete
2: Book Data
incomplete
3: Read File
incomplete
4: Count Words
incomplete
5: Refactor
incomplete
6: Count Characters
incomplete
This lesson's interactive features are locked, please to keep using them
Character counts are the core of BookBot's analysis. We'll store them in a dictionary where each key is a character and each value is the number of times it appears.
To get accurate totals, we can convert all characters to lowercase with the .lower() method. That way uppercase and lowercase letters share one count. Spaces and symbols should also be included in the dictionary.
For example, "Boot!" produces:
{"b": 1, "o": 2, "t": 1, "!": 1}
Run and submit the CLI tests from the root of your project.