 Hi everyone, let's go over question 2 from the Compound Data 1 workshop. So when we are designing arrays, there are three things that we need to think about. First of all, we need to come up with a name. And that name needs to be something meaningful, something that tells the user what it's doing or what it's designed for. The second thing we need to know is how big it needs to be, so how many spaces in memory, what's the size or the length going to be. And then the third thing is the data type. What type of values do we want in our array? So those are the three things. And for these questions at least, it's going to be following this structure. So it might be worth just while you're getting the hang of creating arrays just to copy and paste that structure over to your processing window and fill in the values as you are designing your arrays. So for the first one, I'll do both of these and then after that I'll just do the second one just as an example. So for 2.1 we want to declare and allocate memory for an array to store the number of goals scored by 20 players. So the first thing we need to do is come up with a good name. So goals scored, I'll call this one goals scored 2 because I'm creating two different arrays just so I can show you the two different ways. Next thing we need to know is how big we want our array and it says we want it to store the goals scored by 20 players. So the size is going to be 20. And then our data type, we're counting how many goals are scored so that's going to be an integer. So we'll fill that in there and I've missed this one. Okay, so I've created my array two different ways and you'll notice that they are very similar if not almost exactly the same. It's just that in the first one the declaration and the creation are split up into two different steps. If I was to remove this and move that up to that first line these are exactly the same. So you only need to do this if you're unsure of what your array size will be and perhaps you want to do that later on in your code. If you know the size and you are able to create your array in that scope then you should just do it there. So for the rest of them I'm just going to do it in one line. So 2.2, we want to declare and allocate memory for an array to store the number of days in each month. So again, first of all we need a good name, days in months. Secondly, we want to know how much space. Well, we want to store the number of days in each month. There are 12 months, so 12 spaces and then the data type we want that to be integers because there's a whole number of days in a month. Okay, pretty straightforward. And as we go through these we might start to get the hang of the syntax. Maybe we don't need to copy and paste anymore. Everyone will be at different stages so you just do what works best for you. 2.3, declare and allocate memory for an array to hold the salaries of 5,000 employees. So first of all the name, salaries, the space, we want it for 5,000 employees so it's going to be 5,000 spaces. And then the data type, I guess you could argue int or float. It depends if someone's salary has dollars and cents, maybe it's all dollars, but just to be safe I'm going to do float. So I want the float array called salaries which is a new float array for 5,000 people. 2.4, declare and allocate memory for an array to hold 666 Boolean values. So this one doesn't really tell us the purpose. We can't really give it a meaningful name. I'll just use the name that some of my students came up with for that one there. We know it's going to be Boolean data types and that there are 666 of those. So it's a Boolean array and they call it the devil array which is a new Boolean array with 666 values. And for that last one there we want a array of characters to hold the consonants of the non vowel letters of the English alphabet. So we know it's going to be a character array and then the size for this one I might introduce some variables here. I know that the letters in the alphabet there are 26. I know that my vowels there are 5. So I'm going to do this a little differently. So I have a character array called consonants which is a new character array. And I'm going to use some variables for my size. So you can do that. You can use variables for your size. You can also do some arithmetic in there. That's all okay. Just whatever number that evaluates to will be the size and in this case it's 26 minus 5 and it will be 21. So I could just put 21 in there but I just put that there just to demonstrate to you that you can do arithmetic and you can use variables in here.