Alpha Geek

(8)

$10/per page/Negotiable

About Alpha Geek

Levels Tought:
University

Expertise:
Accounting,Algebra See all
Accounting,Algebra,Architecture and Design,Art & Design,Biology,Business & Finance,Calculus,Chemistry,Communications,Computer Science,Environmental science,Essay writing,Programming,Social Science,Statistics Hide all
Teaching Since: Apr 2017
Last Sign in: 438 Weeks Ago, 1 Day Ago
Questions Answered: 9562
Tutorials Posted: 9559

Education

  • bachelor in business administration
    Polytechnic State University Sanluis
    Jan-2006 - Nov-2010

  • CPA
    Polytechnic State University
    Jan-2012 - Nov-2016

Experience

  • Professor
    Harvard Square Academy (HS2)
    Mar-2012 - Present

Category > Computer Science Posted 27 Apr 2017 My Price 3.00

Write a C++ function named fracpart() that returns

(Numerical)

a. Write a C++ function named fracpart() that returns the fractional part of any number passed to it. For example, if the number 256.879 is passed to fracpart(), the number 0.879 should be returned. Have fracpart() call the whole() function you wrote in Exercise 12. The number returned can then be determined as the number passed to fracpart() less the returned value when the same argument is passed to whole(). The completed program should consist of main() followed by fracpart() followed by whole().

b. Include the function written in Exercise 13a in a working program. Make sure your function is called from main() and returns a value to main() correctly. Have main() use a cout statement to display the returned value. Test the function by passing various data to it.

 

 



Answers

(8)
Status NEW Posted 27 Apr 2017 05:04 AM My Price 3.00

-----------

Attachments

file 1493272419-Answer.docx preview (175 words )
(-----------Num-----------eri-----------cal-----------) a-----------. W-----------rit-----------e a----------- C+-----------+ f-----------unc-----------tio-----------n n-----------ame-----------d f-----------rac-----------par-----------t()----------- th-----------at -----------ret-----------urn-----------s t-----------he -----------fra-----------cti-----------ona-----------l p-----------art----------- of----------- an-----------y n-----------umb-----------er -----------pas-----------sed----------- to----------- it-----------. F-----------or -----------exa-----------mpl-----------e, -----------if -----------the----------- nu-----------mbe-----------r 2-----------56.-----------879----------- is----------- pa-----------sse-----------d t-----------o f-----------rac-----------par-----------t()-----------, t-----------he -----------num-----------ber----------- 0.-----------879----------- sh-----------oul-----------d b-----------e r-----------etu-----------rne-----------d. -----------Hav-----------e f-----------rac-----------par-----------t()----------- ca-----------ll -----------the----------- wh-----------ole-----------() -----------fun-----------cti-----------on -----------you----------- wr-----------ote----------- in----------- Ex-----------erc-----------ise----------- 12-----------. T-----------he -----------num-----------ber----------- re-----------tur-----------ned----------- ca-----------n t-----------hen----------- be----------- de-----------ter-----------min-----------ed -----------as -----------the----------- nu-----------mbe-----------r p-----------ass-----------ed -----------to -----------fra-----------cpa-----------rt(-----------) l-----------ess----------- th-----------e r-----------etu-----------rne-----------d v-----------alu-----------e w-----------hen----------- th-----------e s-----------ame----------- ar-----------gum-----------ent----------- is----------- pa-----------sse-----------d t-----------o w-----------hol-----------e()-----------. T-----------he
Not Rated(0)