Question
Python pls Create a function name word_by_me function, this function will take a dictionary and returns a dictionary that contain word and inner dictionary with
Python pls
Create a function name word_by_me function, this function will take a dictionary and returns a dictionary that contain word and inner dictionary with the name and numbers
Input = {
'Ceaser': [('Indo', 30, 40), ('Death' , 20, 50), ('Indo',-10, 60), ('Apron', 20, 55)],
'Baily': [('Indo', 20, 40), ('Indo',-10, 45), ('Iron', 40, 30), ('Indo',-10, 35)],
'Aaron': [('Indo', 20, 10), ('Death', 10, 50), ('Apron', 80, 80), ('Death', -10, 55)],
'Duke': [('Apron', 40, 80), ('Apron', 40, 85), ('Apron',-40, 90)] }
output = {
'Indo': {'Ceaser': [(30,40), (-10,60)], 'Baily': [(20,40), (-10,45), (-10,35)], 'Aaron': [(20,10)]},
'Death': {'Ceaser': [(20,50)], 'Aaron': [(10,50), (-10, 55)]},
'Apron': {'Ceaser': [(20,55)], 'Aaron': [(80,80)], 'Duke': [(40,80), (40,85), (-40,90)]},
'Iron': {'Baily': [(40,30)]} }
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started