• Post Reply Bookmark Topic Watch Topic
  • New Topic

Factorial  RSS feed

 
veena bijur
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi,


what is the value of fact, though it is not initialized,

what value it takes in fact*c, what's the value of fact

Though fact is not initialized before why no compile time error,

 
Campbell Ritchie
Marshal
Posts: 56536
172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You ought to write out your declarations in better style: one per line. Then you could easily see whether they have been initialised or not.
 
veena bijur
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry, Got it . thanks.
 
Campbell Ritchie
Marshal
Posts: 56536
172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
By the way: what is the largest value you can pass and still get a correct result from your method? What is the smallest value which will return 0?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!