Write a program that takes a string containing a person's name, age, the city they are from, and some other data as an input and unpacks this information into four separate variables, namely name, age, city and miscellaneous. It should print the name of the variable and the information that it contains on separate lines.
Python unpacking operators (* and **)
Exponentiation
Report a typo
Sample Input 1:
Mary, 25, New York, student, unemployedSample Output 1:
name: Mary
age: 25
city: New York
miscellaneous: student unemployedWrite a program in Python 3
info = input().split(', ')
# your code here
___
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.