1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
kari74 [83]
4 years ago
13

Write a C11 program that prompts the user to input the elapsed time for an event in seconds. The program then outputs the elapse

d time in hours, minutes, and seconds. (For example, if the elapsed time is 9,630 seconds, then the output is 2:40:30.)
Computers and Technology
1 answer:
torisob [31]4 years ago
7 0

Answer:

Explanation:

#include <iostream>

using namespace std;

int main()

{

int secondsElapsed, hours, minutes, seconds;

const int secondsPerMinute = 60;

const int secondsPerHour = 60 * secondsPerMinute;

cout << "Please enter the number of seconds elapsed: ";

cin >> secondsElapsed;

hours = secondsElapsed / secondsPerHour;

secondsElapsed = secondsElapsed % secondsPerHour;

minutes = secondsElapsed / secondsPerMinute;

seconds = secondsElapsed % secondsPerMinute;

cout << hours << ":" << minutes << ":" << seconds << endl;

return 0;

}

You might be interested in
What kind of network connection do you think is used to connect most wireless video game controllers to consoles, and why would
Ostrovityanka [42]

Answer:

I would say Lan

Explanation:

5 0
3 years ago
If I delete the emoji free app will I still have the emojis on my phone?
egoroff_w [7]
<span>If you delete the Emoji application from your phone there is a possibility the Emoji's will still hang around. It all depends on the way you set up the app on your phone. Some people opt to have settings and changes to the app saved on their SD card and some don't. If you save updates and changes to the app to your SD card you will still have remnants on your phone after deleting the app</span>
5 0
4 years ago
Read 2 more answers
Which best explains why the world first civilizations developed in river valley's
fiasKO [112]
They need to be close to a body of water and being in a valley is good because they are protected because they have mountains around
4 0
3 years ago
Tin học đã làm thay đổi công tác văn phòng ngày nay như thế nào?
vlabodo [156]
Công nghệ đã thay đổi cách mọi người sử dụng để giao tiếp ở nơi làm việc hiện đại
6 0
3 years ago
Which principle of CSR requires that a business state facts fully and accurately?
DaniilM [7]

Answer: transparency

Explanation:

3 0
3 years ago
Other questions:
  • he wide range of materials used to create the Buk (mask) of the Torres Strait has been interpreted as evidence of the islanders'
    5·1 answer
  • Which of the following statements is true?
    14·1 answer
  • How do buffers work?
    14·1 answer
  • Astrid's computer screen suddenly says that all files are now locked until money is transferred to a specific account, at which
    11·1 answer
  • A corporation needs an operating system that allows the various teams in its office to network and collaborate on projects. Whic
    13·2 answers
  • Does anyone know what to do when brainly won't let you answer questions? I click on answer question and then it just sits there
    15·2 answers
  • How many miss Dragon Ball Abridged?
    5·2 answers
  • Will Give Brainliest
    10·1 answer
  • The abuse of children is a symptom of
    6·2 answers
  • Have a good christmas. this might not be homework, but i just want everyone to have a good week
    6·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!