Nested Dictionary In Python Using For Loop