What are the two floating point types in cpp

Assignment Help C/C++ Programming
Reference no: EM131132079

Part 1: Your city's parking violation bureau wants you to write a program to compute fines for parking violations There are four types of violation: type A carries a fine of $10, type B carries a fine of S20, type C carries a fine of S30, and type D carries a fine of $50.The program should ask for the number of type A violations, the number of type B violations, and so on. The program should display the total fine for the person.

Part 2: Write a program that asks the user to enter a student's grades on four exams. The program should display the four grades and the average of the four grades, rounded to the nearest tenth. To add the grades, use a variable called total_grade, which you should initialize to zero. As the program prompts for and obtains each grade, add the grade to total_grade using the += operator.

REVIEW EXERCISES

1. What are the two floating point types in C++ and how do they differ?
2. How can you use the setprecision() and setiosflags() manipulators to control the output of decimal numbers?
3. Explain how C++ handles an arithmetic expression that contains different numeric data types.
4. What is a type cast and how do you make one? Why is a type cast sometimes necessary?
5. How are data types converted across the assignment operator?
6. What is the value of an assignment expression?
7. Explain how a multiple assignment works
8. What are the compound assignment operators and how do they work?
9. What are the increment and decrement operators and how do they work?
10. What is the difference between pre- and postincrement?

Text Book: C++ For Business Programming Second Edition John C Mulluzzo.

Reference no: EM131132079

Questions Cloud

Define dummy variable and give two examples : Define dummy variable and give two examples. Analyze the three different types of data (cross-sectional, time series, panel data)
Design a gui program to find weighted average of four test : Design a GUI program to find the weighted average of four test scores. The four test scores and their respective weights are given in the following format.
Describe the nondisclosure parameters of this agreement : Identify how these parameters could help safeguard your organization (Caterpillar, Inc.) from the intentional and/or unintentional dissemination of trade secrets by senior executives.
What will carol’s profit be on the stock transaction : What will Carol’s profit be on the stock transaction if its price does rise to $70 and she sells? How much will Carol earn on the option transaction if the underlying stock price rises to $70? How high must the stock price rise for Carol to break eve..
What are the two floating point types in cpp : What are the two floating point types in C++ and how do they differ? How can you use the setprecision() and setiosflags() manipulators to control the output of decimal numbers?
Determine the amount of profit or loss an investor : For each of the 100-share options shown in the following table, use the underlying stock price at expiration and other information to determine the amount of profit or loss an investor would have had, ignoring brokeragefees.
Which type of forecasting tool seemed more appropriate : Which type of forecasting tool seemed more appropriate for the organization you selected-a qualitative or quantitative tool? Why? What do you see as the advantages and disadvantages of each in this specific organizational setting?
Review the assignment reflective journal : Review the Assignment.- Assignment: Reflective Journal - and also check it for flow, citations and referencing?
Were the disney teases of aircraft to united airlines operat : Were the Disney teases of aircraft to United Airlines operating leases or financial lenses?

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Length and the property line

Find the area, in acres, of the property shown in the figure below. The stream frontage is 141 feet in length and the property line is 500 feet in length. Round to two decimal places

  Use a for loop to generate 100 random numbers.

Use a For Loop to generate 100 random numbers. Determine the most current maximum and minimum number as the random numbers are being generated. This is referred tp as a "running" maximum and minimum. Display the running maximum and minimum values as ..

  Create and utilize compound conditions

Eliminate redundancy within a program by applying loops and functions - Create structure charts for a given problem

  Discussing the competitive advantages

Identify an organization with its management information systems. Prepare a report in discussing the competitive advantages and limitations of the systems. Competitive advantages include the benefits for business, organization, employees, and orga..

  Write a driver to thoroughly test your implementation

Write a driver (SortedListArrayDriver) to thoroughly test your implementation. Part of your grade  will depend on evidence of testing. Note that it is not necessary to provide user interaction in your driver class for this program

  Android activity program

Design an app with a single activity that shows the following information about that activity every time that activity is visible to the user. This information should be shown in the layout of that activity

  Write a for loop that displays the following set of numbers

Write a for loop that displays the following set of numbers 0, 5, 10, 15, 20, 25 ...... 500.

  Write a c program that converts celsius temperatures to

write a c program that converts celsius temperatures to fahrenheit temperatures.the formula isf95c 32.f is fahrenheit

  Write a program that uses a function for swapping

Write a program that uses a function for swapping a two numbers. Note: The program requires the user to enter the numbers via the keyboard and determine and display whether a number is odd or even.

  Chess program, enable a monitoring component

Given a chess program, enable a monitoring component to switch planning algorithms at runtime, based on the opposing player's style and response time.

  Struct complex

A complex number can be represented by two parts, real and image. A series complex data can be organized as a group of elements by linked list, which is shown as below: struct Complex

  Program that when a word is entered knows even or odd

I need a program that when a word is entered knows if the word is odd or even of characters and if it is odd it should display the word in a cross and if it's even it should display the word inverted.

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