蒟蒻玄关求调
  • 板块灌水区
  • 楼主bangke
  • 当前回复11
  • 已保存回复11
  • 发布时间2024/8/6 18:55
  • 上次更新2024/8/6 20:03:29
查看原帖
蒟蒻玄关求调
1397811
bangke楼主2024/8/6 18:55
#include<bits/stdc++.h>
using namespace std;
int l,r,ans;
int main(){
	scanf("%d%d",&l,&r);
	for(int i=l;i<=r;i++){
		string s=to_string(i);
		for(int j=0;j<s.size();j++) 					if(s[j]=='2') ans++;
	}
	prinf("%d",s);
}

[错误] 'to_string' was not declared in this scope 这个搜了百度也不知道哪里的问题,帮看看,求轻喷

2024/8/6 18:55
加载中...