Develop an object-oriented programming (OOP) application to create two clocks that display simultaneously and allow for user input using secure and efficient C++ code.1. Clock12: Time should be displayed in 12-hour format where the clock does not exceed 12:59:59. 2. Clock24: Time should be displayed in 24-hour format where the clock does not exceed 23:59:59. 3. Both clocks should display on the screen with the current time in the proper format.

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter4: More Object Concepts
Section: Chapter Questions
Problem 8PE
icon
Related questions
Question

Develop an object-oriented programming (OOP) application to create two clocks that display simultaneously and allow for user input using secure and efficient C++ code.1. Clock12: Time should be displayed in 12-hour format where the clock does not exceed 12:59:59.

2. Clock24: Time should be displayed in 24-hour format where the clock does not exceed 23:59:59.

3. Both clocks should display on the screen with the current time in the proper format.

Any clue where to even start?

Title: Clocks Flowchart
Top of chart begins: “Clear Screen”

  1. “Display time in two formats”.

  2. Decision: “Button Pressed?”

    1. If “No” to button pressed, then to “Add 1 Second”. Then “Wait 1 second”. Then back to “Clear Screen”.

    2. If “Yes” to button pressed, then to “Display Menu”. Then “Read user input”. Then to Decision: “User input = exit?”.

      1. If “Yes” to exit, then endpoint: “End program”.

      2. If “No” to exit, then Decision: “Add Hour?”

        1. If “Yes” to hour, then “Add 1 hour.” Then back to “Clear screen”.

        2. If “No” to hour, then Decision: “Add Minute?”.

          1. If “Yes” to minute, then “Add 1 minute.” Then back to “Clear screen”.

          2. If “No” to minute, then Decision: “Add Second?”.

            1. If “Yes” to second, then “Add 1 Second.” Then back to

              “Clear screen”.

            2. If “No” to second, then back to “Clear screen”.

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 3 images

Blurred answer
Knowledge Booster
Reference Types in Function
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT