Challenge: Retrieving Information from Nested List
Uppgift
Swipe to start coding
You've been provided with the list people
, which includes sub-lists detailing the names and ages of five individuals, as shown below:
Name | Age |
---|---|
Alex | 23 |
Noah | 34 |
Peter | 29 |
John | 41 |
Michelle | 35 |
To extract specific information using indexing, follow these steps:
- Display the details (the entire sub-list) of the fourth person.
- Display the name of the first person.
- Display the age of the fifth person.
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Avsnitt 4. Kapitel 5
single
Fråga AI
Fråga AI
Fråga vad du vill eller prova någon av de föreslagna frågorna för att starta vårt samtal
Suggested prompts:
Sammanfatta detta kapitel
Explain code
Explain why doesn't solve task
Awesome!
Completion rate improved to 1.64
Challenge: Retrieving Information from Nested List
Svep för att visa menyn
Uppgift
Swipe to start coding
You've been provided with the list people
, which includes sub-lists detailing the names and ages of five individuals, as shown below:
Name | Age |
---|---|
Alex | 23 |
Noah | 34 |
Peter | 29 |
John | 41 |
Michelle | 35 |
To extract specific information using indexing, follow these steps:
- Display the details (the entire sub-list) of the fourth person.
- Display the name of the first person.
- Display the age of the fifth person.
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Awesome!
Completion rate improved to 1.64Avsnitt 4. Kapitel 5
single