题解 | #[NOIP2013]记数问题#
[NOIP2013]记数问题
https://www.nowcoder.com/practice/28b2d9f2bf2c48de94a1297ed90e1732
n,x=map(int,input().split()) list1=[] for i in range(1,n+1): if str(x) in str(i): list1.append(str(i).count(str(x))) print(sum(list1))
[NOIP2013]记数问题
https://www.nowcoder.com/practice/28b2d9f2bf2c48de94a1297ed90e1732
n,x=map(int,input().split()) list1=[] for i in range(1,n+1): if str(x) in str(i): list1.append(str(i).count(str(x))) print(sum(list1))
相关推荐