subject

I need to know how I can combine these 4 for loops into one in program Processing - programming language - Java: int x = 0;
background(0);
size (900,500);

rect(400,0,100,100);

for(x = 0; x < 9; x = x + 1)
rect(100*x, 400, 100, 100);

for(x = 1; x < 8; x = x + 1)
rect(100*x, 300, 100, 100);

for(x = 2; x < 7; x = x + 1)
rect(100*x, 200, 100, 100);

for(x = 3; x < 6; x = x + 1)
rect(100*x, 100, 100, 100);

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 18:30
Kto rozmawia z clamentain przez krótkofalówke w the walking dead która śledzi lee w 4 epizodzie
Answers: 1
question
Computers and Technology, 23.06.2019 12:10
2. fabulously fit offers memberships for$35 per month plus a $50 enrollmentfee. the fitness studio offersmemberships for $40 per month plus a$35 enrollment fee. in how many monthswill the fitness clubs cost the same? what will the cost be?
Answers: 1
question
Computers and Technology, 23.06.2019 16:30
20 points archie wants to use a reflector as he photographs a newlywed couple. what would he consider in his choice? a. shadow and sunny b. homemade and professional c. lamps and boards d. incident and reflected e. neutral density and enhancement
Answers: 3
question
Computers and Technology, 24.06.2019 16:00
What is a dashed line showing where a worksheet will be divided between pages when it prints? a freeze pane a split box a page break a print title
Answers: 1
You know the right answer?
I need to know how I can combine these 4 for loops into one in program Processing - programming lang...
Questions
question
Mathematics, 17.02.2020 23:45
Questions on the website: 13722367