Rearrange the lines of code below so that they form a valid script in Python.
Traceback module
Print exception only
Report a typo
Reorder lines using drag or arrows. Adjust indentation with left buttons
try:
print([exception for exception in traceback.format_exception_only(type(e), e)])
print([(people[person]['age'], people[person]['status']) for person in people])
import traceback
except Exception as e:
people = {"alice": {"age": 19, "status": "away"}, "cristian": {"ag": 45, "status": "relaxed"}}
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.