shyam81295's blog

By shyam81295, history, 9 years ago, In English

This is good problem and I think my solution is correct but I am getting SIGFPE error for PRIME GENERATOR. The link of my code is here. This problem has been bugging me for hours. If anyone can solve this doubt, it will be a great help!

  • Vote: I like it
  • 0
  • Vote: I do not like it

»
9 years ago, # |
  Vote: I like it 0 Vote: I do not like it

It is a good idea to check against the worst case.

1 999990000 1000000000

Gives runtime error — https://ideone.com/06tNl2 Usually, SIGFPE means division by zero. I think you made a wrong assumption in your code, but I'll let you figure it by yourself.