CMPSC 101 - Functions Worksheet #4 Name -

1. Write a program that allows the user to input the price of an item as a floating-point value. The main function must call a function named computeTax and pass the inputed value as a parameter. The function computeTax must return the applicable 6% sales tax on the value of the parameter. The main function must then display the final price of the item with the tax included.

 

 
















2. Write a program that includes a function named inputNum . The function is called by the main function and returns an integer that was inputed by the user. The main function must display that inputed value.