AC 哈基米已睡着 · 发布于 2025-08-14 · 浏览 373 回复 0 include <bits/stdc++.h> using namespace std; int main() { int n,m,z=0; cin>>n>>m; while(n<=m){ int t=n; while(t>0){ if(t%10==2){ z++; } t=t/10; } n++; } cout<<z; return 0; }