Question: Assume we have already defined a variable of type int called base and another variable of type int called height with the following lines of

 Assume we have already defined a variable of type int called

Assume we have already defined a variable of type int called base and another variable of type int called height with the following lines of code: // 'base' can have any int value int base = ???; int height = ???; 7/ 'height' can have any int value TASK: Print the area of a triangle with base base and height height. base HINT: Recall that the area of a triangle is half of the product of its base and height. Sample Input: 4 6 Sample Output: 12 height

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!