Create console-based program that presents the user

Assignment Help Programming Languages
Reference no: EM133398488

Your header comment is to include the following information (P4):

A title stating "Your Name Assignment 2"

Name of Project:

Purpose:

Revision History:

Ensure you are using proper programming conventions. For example, proper variable naming, indenting, grouping, etc. Deductions will be made for each style mistake.
When complete, submit a single compressed (.zip format) file containing the entire project folder for both programs, and upload the zip file to the "Assignment 3" dropbox in the class portal.

PROGRAM REQUIREMENTS

Create console-based program that presents the user with a menu of three options. Each menu option will perform a series of calculations, as noted in the instructions below.

Program Logic

Present your user with a menu of 3 options using a do loop.

Any invalid option entered by the user should re-display the menu.
Encapsulate the logic of Option 1 and Option 2 within their own method.
Proper error handling and appropriate error messages should be displayed.
Option 1 - Display a list of 10 sequential numbers that have their values manipulated as noted below, starting from a number that the user specifies.

Start by asking the user for a starting number. Any string entry by the user, in place of the expected numeric value should not crash the program.
Use a for loop to increment through the numbers, beginning with and including the starting number.
For each number multiply the even ones by 3 and multiply the odd numbers by 4.
Display the result of each calculation.
Option 2 - This option should be created using a while loop. The option should present the user with an arithmetic problem (e.g., What is 3 + 8?) and asks for the answer from the user.

The integer numbers for the arithmetic problem should be generated randomly.
Keep presenting the question to the user until they get it right. Then give them a success message.
After the get the correct answer ask the user if they would like another question. Give them another question if the user enters "Yes". If the user enters "No" return to the original menu.

Reference no: EM133398488

Questions Cloud

What are your priorities for this area as the new nurse : What are your priorities for this area as the new nurse tion your team for growth. What communication strategies would you use wit your team?
Produce a design document for modelling and designing : Produce a design document for modelling and designing a computer program based on a given problem statement using a range of UML techniques and Pseudocode
How can a nurse apply ethical principles in decision making : How can a nurse apply ethical principles in decision making? How can a nurse practice principles of accountability and ethical conduct in nursing practice?
What type of patients would be receiving these fluids : What type of patients would be receiving these fluids (ie. PMH,current clinical condition, treatments) and what outcomes do you expect to see?
Create console-based program that presents the user : Create console-based program that presents the user with a menu of three options. Each menu option will perform a series of calculations, as noted
What fallacies are in play here : In the first video, Logan ignores the guidelines for expressing emotions and succumbs to irrational thinking, or fallacies, that lead to debilitative feelings.
Derive and solve the system of state transition equations : CSCE 5760 University of North Texas The failure rate of the memory is m. Derive and solve the system of state transition equations representing this system
What cpt code describes this service : The patient is status post total ethmoidectomy 2 days ago and now presents with headache and a clear nasal discharge when moving the head forward.
Assessing the major economic events influenced supply : Assessing how 2 of the following major economic events influenced supply, demand, and economic equilibrium in U.S. economic activity.

Reviews

Write a Review

Programming Languages Questions & Answers

  Implement a function for computing the achromatic phong

In this question you need to implement a function for computing the achromatic Phong illumination at a surface point.

  Write a method to accepts string as parameter

Write a method called wordCount that accepts a String as its parameter and returns the number of words in the String. A word is a sequence of one or more nonspace characters

  Example on message-passing style

Write a procedure that produces independent first-in-first-out queue objects, using a message-passing style.

  Design employee objects-display each object-s yearly salary

Design two employee objects and display each object's yearly salary. Then provide each employee 10% raise and display each Employee's yearly salary again.

  Why is it significant to use systems analysis

"Why is it significant to use systems analysis and design methodologies when building system? Why not just build system in whatever way seems to be quick and easy?

  Calculate the area and perimeter of a rectangle

Design and write a program, using functions, that calculates the area and perimeter of a rectangle whose dimensions (length and width) are provided by a user.

  Write application layer protocols to permit through firewall

As part of your own planning process, write the application layer protocols which you would permit through the firewall, those you would block and your reasons for doing so.

  Write program to ask user to enter number between a range

Write down program which asks user to enter number between 1 and 100. Use input validation to make sure that a valid number is entered before continuing program.

  Create program which tests each member of resistor class

Create program which tests each member of Resistor class to ensure that they work properly. Complete the following Tasks: Create main function and instantiate three Resistor Class objects: Resistor1, Resistor2 and Resistor3.

  Correct mistakes on the command line

In this lab you will determine the shell that you are running, correct mistakes on the command line, and use filename generation. You will also learn about help that the system provides in the form of man pages, the --help option, and the bash hel..

  Php script to obtain url and its description from user

Write a PHP script to obtain URL and its description from user and stores information into database by using MySQL.

  Software system to manage records of patients

A software system is to be developed to manage the records of patients who enter a clinic for treatment. The records include records of the all regular patient monitoring.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd