 In this video, we're going to examine something called a nested loop, a loop inside of a loop. Here's a program that we're already familiar with. It draws a pentagon. I have a loop variable, pent, that loops five times, 0, 1, 2, 3, and 4. Goes forward 100 pixels and turns right 72 degrees. And when I run it, I get a pentagon. What if instead of going forward 100, I were to draw a square instead? So I would have five squares rotated 72 degrees apart each. Python lets me do that. I can say, for square in range 4, go forward 100 and go left 90 degrees. So now I have a loop inside of a loop. My outer loop in line 12 has an inner loop in line 13. Lines 14 and 15 belong to the inner loop. Line 16 belongs to the outer loop. Let's run that and see what it looks like. And there's my pentagon of squares. Is it possible to nest a loop inside a loop inside a loop? You bet it is. I can put another loop here for try in range 3. And notice that it is indented this for me automatically. But now I'm going to have to indent all these other ones. So what I'll do is I'll highlight them all and Thani makes this easy. Instead of having to do one line at a time, I just press tab and Thani indents everything for me. And then here I have to go left 120 degrees. So I'm going to have a triangular pattern that is made up of a pentagonal pattern of squares. Let's run this and see what it does. How cool is that? Now it's your turn. Try drawing a hexagon of squares. Try drawing a square of hexagons. See what you can do by nesting loops inside of loops.