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
FrozenT [24]
3 years ago
11

Write a program that accepts a time as an hour and minute. Add 15 minutes to the time, and output the result. Example 1: Enter t

he hour: 8 Enter the minute: 15 It displays: Hours: 8 Minutes: 30 Example 2: Enter the hour: 9 Enter the minute: 46 It displays: Hours: 10 Minutes: 1
Computers and Technology
1 answer:
Liula [17]3 years ago
5 0

Answer:

Explanation:

C++ Code

#include <iostream>

#include <cstdlib>

using namespace std;

int main(){

double hour,minute;

cout<<"Enter Hours :";

cin>>hour;

cout<<"Enter Minutes :";

cin>>minute;

minute = minute+15;

if(minute >=60){

 hour++;  

 minute = minute-60;

}

if(hour>23){

 hour = 0;

}

cout<<"Hour: "<< hour<< " Minutes: "<<minute;

return 0;  

}

Code Explanation

First take hours and minutes as input. Then add 15 into minutes.

If minutes exceeds from 60 then increment into hours and also remove 60 from minutes as hours already incremented.

Then check if hours are greater then 23 then it means new day is start and it should be 0.

Output

Enter Hours :9

Enter Minutes :46

Hour: 10 Minutes: 1

You might be interested in
Brian's father drives a car that uses voice commands for navigation. Which Al application field is Brian's father using?
Aneli [31]
O.C speech recognition
8 0
4 years ago
Which similar computer network components connect multiple devices?
Brut [27]

A Network Switch and Network Hub are similar computer network components that connect multiple devices in a computer network.  A Network switch is used to connect various network segments. It is a small hardware device that joins multiple computers together within one local area network (LAN). A Network Hub connects numerous Ethernet devices together, making them act as a single segment.

8 0
3 years ago
Read 2 more answers
You have decided to remove a recently installed feature which method can you use to remove this feature
Aliun [14]
If it is on the desktop screen you just right click on the icon and select delete. from there if you're on a windows computer it goes to your recycle bin then you right click the recycle bin and a little rectangle pops up an in that rectangle it says clear recycle bin and once you press that all of the stuff that was in there is deleted. now if your on a computer that has chrome os installed you just go to the files screen and right click what you want to delete and click delete and it's gone. 
6 0
3 years ago
55555,5555,555,55,5​
REY [17]

Answer: Decreasing Function????????????????????????????????

Explanation:

I'm confused, but I'm still gonna try and answer

6 0
3 years ago
*Sometimes it is difficult to convince top management to commit funds to develop and implement a SIS why*
ziro4ka [17]

Step-by-step Explanation:

SIS stands for: The Student Information System (SIS).

This system (a secure, web-based accessible by students, parents and staff) supports all aspects of a student’s educational experience, and other information. Examples are academic programs, test grades, health information, scheduling, etc.

It is difficult to convince top management to commit funds to develop and implement SIS, this can be due to a thousand reasons.

The obvious is that the management don't see the need for it. They would rather have students go through the educational process the same way they did. Perhaps, they just don't trust the whole process, they feel more in-charge while using a manual process.

4 0
3 years ago
Other questions:
  • A ________ is when teachers develop a professional based network of people selected by him/her to pursue learning needs and shar
    12·1 answer
  • Riley is using access to collect data for a science project. he is creating a report and wants to apply predefined color and fon
    6·1 answer
  • Modify the definition of the throttle class on page 35, to create a new throttle ADT, which allows the user of the ADT to specif
    6·1 answer
  • "This part of the computer fetches instructions, carries out the operations commanded by the instructions, and produces some out
    15·1 answer
  • What can your employer do to protect you from overhead power lines?
    13·1 answer
  • A section in a history book describing the conditions and causes of the Great Depression in the Midwest in the 1930s. a. Enterta
    15·1 answer
  • PHP server scripts are surrounded by delimiters, which? *
    5·1 answer
  • On a scale of 1-10 how would you rate your pain
    12·1 answer
  • Can you help me to write a code with functions,arrays,and pointers in c++?
    5·1 answer
  • hello fellows i need a help.Ineed to know about computer evolutions and computer generations.please hurry.Its my rankover questi
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!