DevJourney · code I wrote while learning

Cardiac Output

2 items

README.md

Single File Programming Question

Problem Statement

Nial is working on a health monitoring system and needs your assistance in creating a program using pointers to calculate the cardiac output based on heart rate and stroke volume.

Write a program that inputs heart rate (in beats per minute) and stroke volume (in milliliters per minute) and calculates the cardiac output using the formula: heart rate * stroke volume.

Note: Convert the cardiac output to liters per minute.

Input format :

The first line of input consists of a double value N, representing the heart rate in beats per minute.

The second line consists of a double value M, representing the stroke volume in milliliters per minute.

Output format :

The output prints a double value, representing the calculated cardiac output in liters per minute, rounded off to two decimal places.

Refer to the sample output for formatting specifications.

Code constraints :

In this scenario, the test cases fall under the following constraints:

1.0 ≤ N ≤ 150.0

1.0 ≤ M ≤ 80.0

Sample test cases :

Input 1 :

60.0 40.5

Output 1 :

2.43 liters per minute

Input 2 :

110.0 75.7

Output 2 :

8.33 liters per minute

Input 3 :

143.0 69.0

Output 3 :

9.87 liters per minute