Question
Create a list with all numbers from 0 to 10. then, make sure to print this list. Create a logic to print only the even
Create a list with all numbers from 0 to 10. then, make sure to print this list.
Create a logic to print only the even numbers from the list you have created in the previous question. *hint: use loops and if/else statements.
A number is divisible by 2 if the reminder, when divided by 2, is 0: in Python notation, number % 2 == 0 returns True if the number if even, and False otherwise.
Create a list containing the square of each number in the list created in Q1. hint: start with an empty list and use a for loop to append squares to this list.
Plot the list of squares created in the previous question.
python pandas
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