Initial release
This commit is contained in:
16
Piège numérique à Pokémons (2).py
Normal file
16
Piège numérique à Pokémons (2).py
Normal file
@@ -0,0 +1,16 @@
|
||||
input = 416
|
||||
|
||||
ctr = 100000000000 + input
|
||||
sol = 0
|
||||
while ctr < 1000000000000:
|
||||
if ctr%10000000000 == 0:
|
||||
print(".", end='')
|
||||
if ctr % input == 0:
|
||||
if str(ctr)[-3:] == str(input):
|
||||
sum = 0
|
||||
for c in str(ctr):
|
||||
sum = sum + int(c)
|
||||
if input % sum == 0:
|
||||
sol =sol + 1
|
||||
ctr = ctr + 1000
|
||||
print(sol)
|
||||
Reference in New Issue
Block a user