Write a program that finds the factorial value of a given number as shown. Display an appropriate error message if the number entered is negative, or too big for the answer to be correctly calculated.

Enter a non-negative integer : 5

5 x 4 x 3 x 2 x 1 = 120

3. Write a program that allows the user to input a monthly investment, annual rate of return (monthly rate is 1/12th) and number of months to track. The program will display the starting balance, interest earned, deposit and ending balance for each month. Here is a sample run :

Monthly Investment : 200
Annual Interest Rate (%) : 12
Term ( Months ) : 4

Starting Interest Monthly Ending
Balance Earned Deposit Balance
-------- -------- ------- -------
0.00 0.00 200.00 200.00
200.00 2.00 200.00 402.00
402.00 4.02 200.00 606.02
606.02 6.06 200.00 812.08

4. Create a simple game of HI-LO, where the computer picks a random number from 1 to 100 and the user guesses at it repeatedly until guessed correctly. After each guess, the computer will say "Higher", "Lower" or "Correct" and keep track of the number of guesses. You will need the following code to access random numbers.

#include<stdlib.h>
randomize(); should be inserted once at start of program
answer = random(100) + 1; will store a random number from 1 to 100 in variable answer

## All 6 Replies

Yeah, I need a million cdn dollars maybe we can work out a deal.

lol seriously sir... its due tomorrow....

Until you show some effort and post some code with specific questions, nobodies going to help you.

doesnt look that hard, I bet you have a lot of simillar example if you have notes??
the only problem I cant help you because I am doing a project taking me a month of non stop coding, :/

doesnt look that hard, I bet you have a lot of simillar example if you have notes??
the only problem I cant help you because I am doing a project taking me a month of non stop coding, :/

no problem....:)