1. In this part of the lab, the code started with the creation of three variables, in my case they were called R,G,B, representing red, green and blue. In the void draw, an if statement was used, which determined when the mouse is pressed and the action it should perform. Then the coordinates and colors for the shapes are entered, so that they can be drawn. On the last part the if statements allow that when the mouse is pressed on the green or pink shape, the R,G.B variables, take the numbers that are given to it, and the user is able to draw with those colors.

    In this part of the lab, the code started with the creation of three variables, in my case they were called R,G,B, representing red, green and blue. In the void draw, an if statement was used, which determined when the mouse is pressed and the action it should perform. Then the coordinates and colors for the shapes are entered, so that they can be drawn. On the last part the if statements allow that when the mouse is pressed on the green or pink shape, the R,G.B variables, take the numbers that are given to it, and the user is able to draw with those colors.