Industry-relevant training in Business, Technology, and Design to help professionals and graduates upskill for real-world careers.
Fun, engaging games to boost memory, math fluency, typing speed, and English skillsβperfect for learners of all ages.
Test your understanding with targeted questions related to the topic.
Question 1
Easy
Create a list of the first 5 odd numbers using list comprehension.
π‘ Hint: Use a range and an if statement to only include odd numbers.
Question 2
Easy
What is the output of this code: list(map(str, [1, 2, 3]))
?
π‘ Hint: It's converting numbers to strings.
Practice 4 more questions and get performance evaluation
Engage in quick quizzes to reinforce what you've learned and check your comprehension.
Question 1
What does the map function return in Python 3?
π‘ Hint: Remember the type of object that map produces in Python 3.
Question 2
True or False: Using a single list of zeros for multiple rows will create independent rows.
π‘ Hint: Think about how the references work in memory for lists.
Solve and get performance evaluation
Push your limits with challenges.
Question 1
Write a function using list comprehension that generates prime numbers less than 100.
π‘ Hint: Consider the condition a number needs to satisfy to be prime.
Question 2
Create a 5x5 matrix where each element is the product of its row and column indices.
π‘ Hint: Think of the values you need to calculate for each cell based on its position.
Challenge and get performance evaluation