| # | Problem | Pass Rate (passed user / total user) |
|---|---|---|
| 14667 | Compute area of a rectangle in 2D space |
|
| 14668 | Compute surface area and volume of a cuboid |
|
Description
Given a rectangle in the 2D space with four coordinates are (a, c), (b, c), (a, d) and (b, d), compute its area.
Note that b may be greater or less than a, and the same as d and c.
You may use abs function as an assistant to solve this problem (by including <stdlib.h>)
Input
Four integers are given as input: a, b, c, and d, in that order.
Output
Positive integer rectangle area.
Ensure that the output, including formatting, exactly matches the provided samples.
Sample Input Download
Sample Output Download
Tags
Discuss
Description
Input three parameters: length, width and height as a cuboid.
Compute its surface and volume.
Input
Input three integers, length, width and height in order.
Output
Two integers, surface area and volume.
Ensure that the output, including formatting, exactly matches the provided samples.