Home Forums C Programming ‘while’ statement ??

Viewing 1 reply thread
  • Author
    • #2164

      Hi, as i said i am new to all this computer stuff, I think that if i can see how codes are written a few times, then i can start to understand it better. Please help me to better understand this language.

      Write a C program using a while-statement to compute n factorial (n!) of a nonnegative integer n where
      p = 1 (for n = 0)
      p = double = n*(n-1)*(n-2)*…*2*1 (for n€1)
      „ For example : 5! = 5*4*3*2*1 = 120
      „ Prompt user to enter the value of n, computes
      and prints its factorial (p)

      Best wishes ……..daisy

    • #3490

      could do:

Viewing 1 reply thread
  • The forum ‘C Programming’ is closed to new topics and replies.