Exercise: count digits
examples/files/numbers.txt
23 345 12345 67 189 23 17
- Given the file examples/files/numbers.txt (or a similar file), create a file called count_digits_in_file.py that will count how many times each digit appears? The output will look like this. Just different values.
- Save the results in a file called report.txt.
0 0 1 3 2 3 3 4 4 2 5 2 6 1 7 2 8 1 9 1