iwebie
HOME MOVIES TV SHOWS SPORTS GENERAL
 RSSPRIVACY
 

Java Factorial Program
Posted by admin on July 6th, 2008

Watch over 100,000 movies and TV shows on your PC

[sourcecode language='java']
public class Factorial {

public static long factorial(int n) {
if (n <= 1)
return 1;
else
return n * factorial(n – 1);
}

public static void main(String[] args) {
for (int i = 1; i <= 10; i++)
System.out.println(”Factorial of “+i+” : “+factorial(i));
}
}
[/sourcecode]

Bookmark Article
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • StumbleUpon
  • Technorati
  • Propeller
One Response to “Java Factorial Program”
  1. me Says: March 5th, 2009 at 6:49 pm

    i want u to use the bufferedreader but its iok.

Leave a Reply

Most Popular

Watch over 100,000 movies and TV shows on your PC
Recent Posts

  • Watch Dexter Season 4 Episode 9 | Dexter Hungry Man Online Video
  • Californication Season 3 Episode 9 | Watch Mr. Bad Example Full Episode
  • Watch The Amazing Race Season 15 Episode 9 | The Amazing Race s15e09 Full Video
  • English Premier League | Watch Aston Villa vs Burnley Streaming Live
  • Stargate Universe Season 1 Episode 9 | Watch Stargate Universe s01e09 Life Video Online
  • Smallville Season 9 Episode 9 | Watch Smallville s09e09 Pandora Online Free
  • Monk Season 8 Episode 14 | Watch Mr. Monk and the Badge Streaming Video
  • Community Episode 10 | Watch Community s01e10 Environmental Science Stream Online
  • Watch It’s Always Sunny in Philadelphia Season 5 Episode 10 Full Episode
  • Survivor: Samoa Episode 10 | Watch Survivor s19e10 The Day of Reckoning Free Online
Archives

  • November 2009
  • October 2009
  • September 2009
  • August 2009
  • July 2009
  • June 2009
  • May 2009
  • April 2009
  • March 2009
  • February 2009
  • January 2009
  • December 2008
  • November 2008
  • October 2008
  • September 2008
  • August 2008
  • July 2008
  • June 2008
Powered by WordPress