Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

3.1. Write a program that generates a random double base (b) and height (h) for a triangle in the range 5 to 10 , inclusive,

image text in transcribed
3.1. Write a program that generates a random double base (b) and height (h) for a triangle in the range 5 to 10 , inclusive, and then computes the area of the iriangle and shows it with three decimal points. (15 marks) 3.2. Ask the user to input a base and height for a second triangle in range of 10 to 20 and then print the ratio of the area of the first triangle to this new triangle in percentage with currect formatting. ( 5 marks)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database And Transaction Processing

Authors: Philip M. Lewis, Arthur Bernstein, Michael Kifer

1st Edition

0201708728, 978-0201708721

More Books

Students also viewed these Databases questions

Question

riley dynamics

Answered: 1 week ago