33分,U361947 字符串处理
查看原帖
33分,U361947 字符串处理
1030094
__Crafty_Wolf__楼主2023/10/3 15:15
#include<bits/stdc++.h>
using namespace std;

int my_getlen(string a){
	int cnt=0;
	while(a[cnt]!='\0') cnt++;
	return cnt;
} 

int main(){
	string a,b;
	cin>>a>>b;
	cout<<my_getlen(a)+1<<endl<<my_getlen(b)+1;
} 
2023/10/3 15:15
加载中...