Created
May 1, 2016 03:24
-
-
Save rosiecakes/e0fd651a079daa243606edfe9443e252 to your computer and use it in GitHub Desktop.
This file contains 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 find_next_prime(n): | |
n+=1 | |
for i in range(2, n): | |
if n%i == 0: | |
n += 1 | |
else: | |
print n | |
pass | |
find_next_prime(6) | |
find_next_prime(10) | |
find_next_prime(11) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment