Why KeyError: 0
I’m attempting to solve Project Euler 21 but I’m getting KeyError: 0 which normally occurs when you refer to a dictionary key that doesn’t exist. However, I thought I had solved that problem with the < 10000 condition. The error refers to the first ‘if’ statement in the main() function. Any ideas?