Skip main navigation

Welcome to Week 3

Welcome week 3
<v ->Welcome to week three.</v> So this week you’re going to work with loops and lists. You’re going to be able to predict the output of code with loops and lists. Also use the range function when you’re looping through things. You’ll be able to use a for-each loop to traverse a string or a list, a for loop that has a range, or a while loop. You’ll also compare two adjacent values as you’re looping through a list. Also show you how to use list comprehensions as a way to make your code even shorter and filter data. And then I also want you to know how to justify which type of loop you should use when you’re working on a problem.
And then for our assignment, you’re gonna create ASCII art. So hope you have a great time this week, enjoy.

. . . . . . . . . . . . . . . . . .

This video introduces the topic of loops. Loops allow you to iterate through a statement or block of statements a certain amount of times with a for-each loop, general for loop, or a while loop.

This article is from the free online

Big Ideas in Programming: Expressing Yourself with Python

Created by
FutureLearn - Learning For Life

Our purpose is to transform access to education.

We offer a diverse selection of courses from leading universities and cultural institutions from around the world. These are delivered one step at a time, and are accessible on mobile, tablet and desktop, so you can fit learning around your life.

We believe learning should be an enjoyable, social experience, so our courses offer the opportunity to discuss what you’re learning with others as you go, helping you make fresh discoveries and form new ideas.
You can unlock new opportunities with unlimited access to hundreds of online short courses for a year by subscribing to our Unlimited package. Build your knowledge with top universities and organisations.

Learn more about how FutureLearn is transforming access to education