Question: Write a static method named randomRightTriangles that calculates and displays the area of randomly-generated right-angled triangle. The base and height of each triangle should be


Write a static method named randomRightTriangles that calculates and displays the area of randomly-generated right-angled triangle. The base and height of each triangle should be a randomly generated integer between 1 and 10 inclusive. Your method should keep generating random right-angled triangles until a strictly increasing sequence of 3 areas is printed. In other words, if the last 3 right-angled triangles generated have areas of a1,a2 and a3 such that a1
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
