News All About

  1. class factorial{
  2. public static void main(String args[]){
  3. int i, fact=1;
  4. int n=5;
  5. for(i=1;i<=5;i++)
  6. {
  7. fact=fact*i;
  8. }
  9. System.out.println(“Factorial of “+ n+ ” is: “+fact);
  10. }
  11. }
  12. Simple Contact Form

Leave a Comment

Your email address will not be published. Required fields are marked *

Open chat
1
Hello,
How Can we Help You!