Created
September 4, 2016 17:09
-
-
Save ooade/12adc226c815a8f52faa192a70dd541a to your computer and use it in GitHub Desktop.
Prime number
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def is_prime(x): | |
| if x < 2: | |
| return False | |
| for i in range(2, x): | |
| if x % i == 0: | |
| return False | |
| return True |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment