 Hi everyone. I'm just going to go over question 4 from the week 5 workshop and I'm going to complete this question using Modulus. So question 4 asks you firstly to write a program that draws a circle with a radius of 50 whenever the user clicks the mouse. And the circle should stay on the screen when later circles are drawn. So I've gotten that far. I've got my two variables here. I've got a radius variable which has 50. So that when I apply my radius I'll multiply it by 2 because this is the width and the height of our circle. And I've also created a counter variable here just so I can keep track of how many circles I've drawn on the screen. So I've got my mouse press method here that draws an ellipse every time I press the mouse at mouse x mouse y. And I also have my little print line statement here just so I can keep track of my circles here. And just to get into the habit we're going to start with 0 so we can count starting from 0. So that's circle number 0, circle 1, 2, 3, 4, etc. So we've got that working so far. That's good. The second part is where it gets a little bit tricky. So the circle should be filled with yellow, purple and blue in the order that they appear. So the first circle should be yellow, the second should be purple, the third should be blue and then that process should be repeated. And we can do that using conditionals and those conditionals will involve a bit of modulus. So I'll just explain what I mean here. So here I've got the numbers of the circles I want to draw. So the first circle I want to draw should be yellow and that circle labeled 0. The second one should be purple, the third one should be blue or circle number 2 should be blue. And then we should go back to yellow like that. So we want to use our counter to determine which colour our ellipse should be. And there's three different options of three different colours we want our ellipse to be. We've got yellow, purple or blue. And because we have three different options here, we can use modulus 3. So if I take the label of my ellipse, say label 0 and do modulus 3, well in this case I'll get 0. If I take my second one which should be purple and do one modulus 3, I'll get 1 because there will be one remainder. When I do my third one which will be blue and I do two modulus 3, I get 2 because there's two remainder. And when I do three modulus 3 that goes in evenly and I get 0. If we have a look at number 4, 4 modulus 3, 3 goes into 4 once evenly with one remainder. 5 modulus 3, 3 goes into 5 once with two remainder. And then we've got 6 modulus 3 which goes into, 3 goes into 6 twice with no remainder so we get 0. And that pattern continues. So as you can see here, when you do modulus 3, you will get three distinct answers and they align here. So all of your yellows will always get 0, all of your purples will always get 1 and all of your blues will always get 2. So we can use modulus to determine which colour our lips should be. So let's have a look. So we want a conditional here. So if our counter modulus 3 is 0, well we said when we get 0 our colour should be purple. Sorry, our colour should be yellow. Give us a yellow. If when we do modulus 3 we get a remainder of 1, we know it should be purple. So our fill should be purple. Otherwise it should be blue. And I forgot a comma here. So now yellow, purple, or sort of pink, but it's fine. Yellow, purple, blue, yellow, purple, blue.