Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static void factor(){
- int n=0;
- int factorial = 1;
- while (n<=0&n<=30)
- {
- n=n++;
- factorial = factorial * n;
- n--;
- System.out.println("Factorial = " + factorial);
- }
- }
- public static void main(String[] args) {
- factor();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement