![]() |
|
#1
|
|||
|
|||
Writing code for a program in CTryin to learn c prog on my own at home.... havin a hard time with a few of the review Q's
What i need to do: The factorial of a non-negative integer n is written n! (pronounced "n factorial") and is defined as follows: n! = n * (n-1) * (n-2) * ... * 1 (for values of n greater than or equal to 1) and 0! = 1 For example 5! = 5*4*3*2*1, which is equal to 120. Write a program that inputs a non-negative integer and computes and prints its factorial. Use a "while loop" as part of your program implementation. only between 0 and 12 . heres my psudocode Code:
thx ... Last edited by LuciWiz : 08-Jun-2005 at 23:47.
Reason: Inserted code tags...
|
|
#2
|
||||
|
||||
|
You should read the sticky. You forgot an important posting point, namely you have to ask a question and/or tell us the trouble you are having.
__________________
Age is unimportant -- except in cheese |
Recent GIDBlog
Toyota - 2008 August Promotion by Nihal
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Guidelines for posting requests for help - UPDATED! | WaltP | C++ Forum | 1 | 22-Aug-2008 00:07 |
| Problem with int mixed with char,... | leitz | C++ Forum | 17 | 07-Dec-2004 20:56 |
| Anyone can write a program code for this??? | chriskan76 | C Programming Language | 1 | 19-Oct-2004 20:25 |
| very difficult code - program | gaurav_sting | C++ Forum | 1 | 16-Jun-2004 00:59 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The