摘要: A 门牌号 题意:统计 \([1,2020]\) 所有整数中,数码 $2$ 出现的次数 分析:直接暴力枚举即可: inline int f(int n){ int ans=0; while(n) ans+=(n%10==2),n/=10; return ans; } ... int ans=0; f 阅读全文
posted @ 2020-11-10 22:28 JustinRochester 阅读(1636) 评论(0) 推荐(0) 编辑