2
answers
0
watching
210
views
24 Oct 2018
22. What expression goes in the blank so this program draws a red ball when the mouse is pressed and a black ball otherwise? Check all that apply. void draw() { background (255); drawBall (mousex, mousey, A. mousePressed == true B. mousePressed C. !mousePressed D. mousePressed == false void drawBall (int x, int y, boolean red) { if (red) fill (255, 0, 0); else { fill(0); ellipse (x, y, 40, 40);
22. What expression goes in the blank so this program draws a red ball when the mouse is pressed and a black ball otherwise? Check all that apply. void draw() { background (255); drawBall (mousex, mousey, A. mousePressed == true B. mousePressed C. !mousePressed D. mousePressed == false void drawBall (int x, int y, boolean red) { if (red) fill (255, 0, 0); else { fill(0); ellipse (x, y, 40, 40);
16 Feb 2023
Hubert KochLv2
25 Oct 2018
Already have an account? Log in