MATH_BUG01

Following code tries to figure out if a number is prime ( Wiki )
However, it has a bug in it.
Please correct the bug and then submit the code.

Interview Code Editor
Hints
  • Solution Approach
  • Complete Solution
10484 successful submissions.
Click here to jump start your coding interview preparation