Question: Write a program that displays 500 colored triangles on the screen. You must choose the color of each triangle randomly by selecting random values for
Write a program that displays 500 colored triangles on the screen. You must choose the color of each triangle randomly by selecting random values for the amount of red, green, and blue. Then select three random points for the vertices of the triangle. Each vertex will require two random numbers: one random x-value and one random y-value. This means that each triangle requires nine random numbers. Finally, put all this stuff inside a loop that repeats 500 times
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
