ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1104. Don’t Ask Woman about Her Age

Whats wrong with my code??
Posted by Андрей 14 Nov 2022 00:44
found = False
s= str(input())
for k in range (2, 37):
    try:
        h = int(s, k)
        if h%(k-1)==0:
            print(k)
            found = True
            break
    except:
        pass

if not found:
    print('No solution')