Sunday, January 25, 2009

How to create Factorial using java?

I have here an example getting the factorial of the given value in this example i used
import.java.io.*; its a kind of package in java in order the user will input a number.
IO means
Input and Output
. For example if the user will input 5 basically the factorial of 5 is 120 i have here a formula getting 120.

5 is the user input

solution
1 x 2 x 3 x 4 x 5 = 120

In order we can get the 120 in java we will use for loop statement on of the loop statement in java. Here the Output!

****
****OUTPUT**********












You can download my example below.

Download File


2 comments:

  1. Actually you can download above. please click the Download File above. :D

    ReplyDelete

 

blogger templates | Make Money Online