Write a program that reads in hours, minutes, and seconds as input, and outputs the time in seconds only. Ex: If the input is: 1 6 40 where 1 is the number of hours, 6 is the number of minutes, and 40 is the number of seconds, the output is: Seconds: 4000

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter6: User-defined Functions
Section: Chapter Questions
Problem 30SA
icon
Related questions
Question

Write a program that reads in hours, minutes, and seconds as input, and outputs the time in seconds only.

Ex: If the input is:

1 6 40

where 1 is the number of hours, 6 is the number of minutes, and 40 is the number of seconds, the output is:

Seconds: 4000

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Similar questions
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning