 Hi everyone in this video. I'm going to look at question 3 from the PDPS workshop. So this question is similar to question 1. We want to refactor this code because at the moment it doesn't look great. We can't really tell what it's doing just by looking at it. And what we can do to improve this is by adding some indentation. So again, like what I said was question 1, it's good to try doing this in another text editor. So notepad, whatever you want to use, I'm going to use sublime text because it's all too tempting with processing to just do the shortcut to reformat it for you, indent it for you. But in the exams, you won't have that. So it's good to practice indenting on your own. So there's a few tricks to just get the layout a little nicer because at the moment it's not. And one of those tricks is to find every semicolon and make a new line every time you see a semicolon. Because usually that's showing that it's the end of the line. The only case where that doesn't, I'm sure there's other cases, but the only case that we're concerned with where that doesn't apply is inside for loops. So if you recognize a for loop like this one, we won't do a new line for those semicolons. But we can for the rest of them just to make this nicer straight away. So every semicolon, I'm going to hit enter. Oh, in fact, I've missed one. I think it's indented for me. Shouldn't have done that. Not many semicolons here. There we go. Okay, so our setup method is looking a little nicer. So another thing we can do, so I'll write them down the bottom again. New line for every semicolon. Another thing is a new line for every curly bracket. So this one here, that's automatically indented. So maybe the blind text isn't a good one to use, probably notepad. New line here, new line here. And there we go. Awesome. So that's what you want to do first just to space it out so you can see what you're looking at. And then again, we want to do some indentation. So indent inside each scope. So function, loop, conditional, every time you enter a curly bracket. Okay, so we can see that everything inside our setup function needs to be indented and we do that with two spaces. Or I guess if you're in the exam and you don't think that two spaces is quite obvious enough, you can do four, whatever you like, as long as it's consistent. We also need to indent everything inside draw. So the draw closing bracket is the lowest one there. So the key is to have each curly bracket line up with what it belongs to. So everything inside setup looks fine to me. So it'll just be draw. So we know that we indent inside each conditional scope. So this is my if condition and this is its closing bracket. So this needs to be in line with the if. So we indent everything else inside it. So two more spaces. And then we have our for loop and we want to indent everything inside there. And that bracket should line up with the for there. So another two spaces. Cool. And that's all you have to do for that question. And again, I just want to reiterate it's a good idea if you're doing another exam, not necessarily PDPS, where you need to write some code, especially if you've got functions loops and conditionals all in one. It's very easy to forget about these brackets. So I would indent your code just to make sure that you have enough brackets and that they line up with your fours and your ifs and your function headings. It just stops you from making those small mistakes, especially when you've got such a short time to complete the exam. It will just, you won't have to look through all your code and wonder, do I have all the brackets need to analyze it? But if you're indenting as you go, then you won't have to worry about that. And that's what question three looks like.