Answer:
How to convert the hours into minutes and seconds?
We know that there are 60 minutes in an hour, and there are 60 seconds in a minute. But here, we only have the value of hours as an input. We have to convert that input into minutes and seconds. So, the formula to convert the hours into minutes and seconds is -
Now, let's see the programs to convert the hours into minutes and seconds.
<em>a program to convert the hours into minutes and seconds in C language :</em>
#include <stdio.h> void conversion(float hours) { double minutes, seconds; minutes = hours * 60; seconds = hours * 3600; printf("There are %lf minutes in %f hours", minutes, hours); printf("\nThere are %lf seconds in %f hours", seconds, hours); } int main() { float hours; printf("Enter the value of hours: "); scanf("%f", &hours); conversion(hours); return 0; }
Answer:
I only do Design and Technology
sorry don't understand.
Answer:
The program is as follows:
10 INPUT RADIUS, BASE, HEIGHT
20 CIRCLE = 3.142* RADIUS * RADIUS
30 TRIANGLE = 0.5* BASE * HEIGHT
40 PRINT CIRCLE
50 PRINT TRIANGLE
60 STOP
Explanation:
The program description doesn't tally;
In other words, it is impossible to calculate the area of a triangle using the radius of a circle.
So, I designed the program to get input for radius, base and height.
Get input for radius, base and height
10 INPUT RADIUS, BASE, HEIGHT
Calculate area of circle
20 CIRCLE = 3.142* RADIUS * RADIUS
Calculate area of triangle
30 TRIANGLE = 0.5* BASE * HEIGHT
Print area of circle
40 PRINT CIRCLE
Print area of triangle
50 PRINT TRIANGLE
End of program
60 STOP