문제) 답안) N = int(input()) def main(): if (N < 100): print(N) return num_cnt = 99 for i in range(100, N+1): hun = int(i / 100) ten = int((i % 100) / 10) one = int(i % 10) if (hun-ten) == (ten-one): num_cnt += 1 print(num_cnt) if __name__=="__main__": main()