Skip to content

Added a new Algorithm to check if a number is prime or not. #487

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Oct 19, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fixed Minor Formatting issues
Github Merged the 2 previous and current version to make a weird file.
  • Loading branch information
Kaiyoto committed Oct 19, 2018
commit c4ebbe017024397ac384cecb706c78967b3331d9
4 changes: 0 additions & 4 deletions Maths/PrimeCheck.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
def primeCheck(number):
prime = True
<<<<<<< HEAD
for i in range(2, int(number**(1/2)+1), 2):
if i != 2:
i = i - 1
=======
for i in range(2, int(number**(0.5)+1), 2):
>>>>>>> 3577f97de113fca832f514b96b2b18d0acc2f39a
if number % i == 0:
prime = False
break
Expand Down