Created
July 31, 2016 11:48
-
-
Save prakashgd/03a0af4827f61fabdea46c2f4c4002ba 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
n = int(input("Enter your number")) | |
d = n - 1 | |
x = 2 | |
dvr = [] | |
while 2 <= x <= d: | |
y = n % x | |
if y == 0: | |
dvr.append(x) | |
x += 1 | |
else: | |
x += 1 | |
print "The divisor of {} are : {}".format(n, dvr) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment