The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | May 2017 |
| Last Sign in: | 398 Weeks Ago, 5 Days Ago |
| Questions Answered: | 66690 |
| Tutorials Posted: | 66688 |
MCS,PHD
Argosy University/ Phoniex University/
Nov-2005 - Oct-2011
Professor
Phoniex University
Oct-2001 - Nov-2016
(Useful Utility)
a. Write a C++ function named fracpart() that returns the fractional part of any number passed to the function. For example, if the number 256.879 is passed to fracpart(), the number .879 should be returned. Have the fracpart() function call the whole() function you wrote in Exercise 5a. 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().
b. Include the function written in Exercise 6a in a working program. Make sure the function is called from main() and correctly returns a value to main(). Have main() use a cout statement to display the returned value. Test the function by passing various data to it.
c. When you’re confident the fracpart() function written for Exercise 6a works correctly, save it in the same namespace and personal library selected for Exercise 5c.
Â
Hel-----------lo -----------Sir-----------/Ma-----------dam-----------Tha-----------nk -----------You----------- fo-----------r u-----------sin-----------g o-----------ur -----------web-----------sit-----------e a-----------nd -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n.P-----------lea-----------se -----------pin-----------g m-----------e o-----------n c-----------hat----------- I -----------am -----------onl-----------ine----------- or----------- in-----------box----------- me----------- a -----------mes-----------sag-----------e I----------- wi-----------ll