Question: CHALLENGE ACTIVITY 8.4.4: Creating a named tuple Define a named tuple player that describes an athlete on a sports team. Include the fields name, number,
CHALLENGE ACTIVITY 8.4.4: Creating a named tuple Define a named tuple player that describes an athlete on a sports team. Include the fields name, number, position, and team 1 from collections import namedtuple 3 Player - Your solution goes here 5 cam - Player('Cam Newton', 'l', 'Quarterback', 'Carolina Panthers') 6 lebron - Player('Lebron James', '23', 'Small forward', 'Los Angeles Lakers') 8 print(cam.name + "(#" + cam, number + '.' + ' is a + cam. position for the " + cam.team + '.') 9 print(lebron.name + (8 + lebron.number + ') +' is a' + lebron.position for the ' + lebron.tean
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
