Reference no: EM131306337
Exam Program: Create a class for working with mixed fractions. Only 3 private data members are needed: the int whole number part of the fraction, the int numerator of the fraction, and the positive int denominator of the fraction. For example, the fraction 3 5/8 will have the three private data member values of 3, 5, and 8.
The following methods should be in your class:
a. A default constructor that should use default arguments in case no initializers are included in the main. The fraction needs to be stored in reduced form. Make sure the denominator is not set to 0 or a negative value.
b. Add two mixed fractions and store the sum in reduced form.
c. Subtract two mixed fractions and store the difference in reduced form.
d. Multiply two mixed fractions and store the product in reduced form.
e. Divide two mixed fractions and store the quotient in reduced form
f. Print a mixed fraction.
g. Change a fraction to its reciprocal. For example, the reciprocal of the fraction 3 5/8 is 8/29. The reciprocal of 4/19 is 4 3/4.
Your main should instantiate two mixed fractions and call each of the class methods. The two mixed fractions should be printed along with the sum, difference, product, quotient, and after being changed to its reciprocal. (Please do not overload the operators for this program.)
What is addition to retained earnings
: California Retailing Inc. has sales of $4,000,000, the firm's cost of goods sold is $2,500,000, and it’s total operating expenses are $600,000. The firm’s interest expense $250,000, and the corporate rate is 40%. The firm paid dividends to preferred ..
|
Do the organizations compete with one another
: You'll also want to discuss how the two are related - do they have similar missions, but differ in their geographic focus? Do the organizations compete with one another? Do they collaborate?
|
What is the present value of investment
: Dynamics Telecommunications Corporation has made an investment in another company that will guarantee it a cash flow of $22,500 each year for the next five years. If the company uses a discount rate of 15 percent on its investments, what is the pres..
|
The task is to analyze available sources of finance
: The task is to analyze available sources of finance for a selected SME entity. What sources of finance are available for the selected entity? What is the cost of capital in your selected company based on your previous learning?
|
Create a class for working with mixed fractions
: Create a class for working with mixed fractions. Only 3 private data members are needed: the int whole number part of the fraction, the int numerator of the fraction, and the positive int denominator of the fraction.
|
What is the current price of jeeps stock
: Jeep recently paid a dividend of $1.25. Dividends are expected to grow at a 10% percent rate for the next three years. Beginning in the fourth year, revenue growth is expected to slow and thus dividends are expected to slow to 4% thereafter. If the c..
|
What is the yield to maturity of the bond
: A five--year, $5,000 bond with a 4.5% coupon rate and semiannual coupons is currently trading for a price of $4,876. What is the yield to maturity of the bond?
|
Ways an individual might handle a cash flow deficiency
: Name some ways an individual might handle a cash flow deficiency. Which way would be preferable? Why?- What is the opportunity cost of having excessive amounts of liquid funds?
|
Mortgage lender-what will his monthly payment be
: Patrick is purchasing a new home and needs to borrow $250,000 from a mortgage lender. The mortgage lender quotes him a rate of 6.25% APR for a 30--year fixed rate mortgage. What will his monthly payment be?
|