Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Programming Exercise #ex2_1 1. Create a new text file named ex2_1.cpp with the following two lines. Be sure to replace the string Your FullName with

image text in transcribed
Programming Exercise #ex2_1 1. Create a new text file named "ex2_1.cpp" with the following two lines. Be sure to replace the string "Your FullName" with your real full name. /*Filename: ex2_1.cpp Student: Your Full Name */ 2. Next to the above two lines, write a CH+ program that will declare two variables of proper data types: "totalValue" and "totalHour". Then, ask users to enter a value to be stored in the "totalValue" variable and a value to be stored in the "totalHour" variable. (Be sure to choose the proper data type(s) for the "totalValue" and "totalHour" variables total value of work 3. One way to calculate the productivity is expressed by the following formula: productivity For example, the productivity of a nation is measured using GDP per worker of $90,000 and average annual hours worked of 1600. The value is computed by: productivity = $90,000 = $56.25 per hour. total hours worked 1600 4. Write a C++ code to perform the calculation based on the above formula. Then, display the output on the screen. 70 Penn P. Wu, PhD - CH Programming Developer Command Prompt for FRESCI1230x21 Enter the total value of works 95042 Enter the total hours of worked: 1657 productivity - $57.72 cscf123x2_1 Enter the total value of work: 175269 Enter the total hours of worked: 25436 productivity - $6.89859

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

DB2 Universal Database V7.1 Application Development Certification Guide

Authors: Steve Sanyal, David Martineau, Kevin Gashyna, Michael Kyprianou

1st Edition

ISBN: 0130913677, 978-0130913678

More Books

Students also viewed these Databases questions

Question

3. What may be the goal of the team?

Answered: 1 week ago

Question

Is how things are said consistent with what is said?

Answered: 1 week ago

Question

Has the priority order been provided by someone else?

Answered: 1 week ago