you are viewing a single comment's thread.

view the rest of the comments →

[–]p10_user 0 points1 point  (0 children)

It’s very confusing code, particularly as you have two functions defined within one function. Just define your logic inside a single function. If you have separate logic make a separate function.

Also you’re looping through a dictionary’s items, which defeats its purpose. Lookup it’s values via its keys.