打卡记录 第 N 位数字(找规律) 链接 class Solution:def findNthDigit(self, n: int) -> int:count, digit, start = 9, 1, 1while n > count:n -= countdigit += 1start *= 10count = start * 9 * digitnum = start + (n - 1) // digitreturn int(str(num)[(n - 1) % digit])