How would you write a while loop to print all even numbers from 1-10?

i = 2while i <= 10: print(i) i += 2

CL

Related Python Mentoring answers

All answers ▸

What is the difference between a for loop and a while loop?


What is the difference between using range() and a list of values?


Manually implement a function that finds the smallest value in a list of integers and print it.


h