AC

 •  5天前


include<bits/stdc++.h>

using namespace std; int main(){

string s1,s2;
cin>>s1>>s2;
if(s1==s2){
	cout<<0;
	return 0;
}
int m=0,n=0;
while(1){
	if(m>=s1.length()||m>=s2.length()){
		break;
	}else if(s1[m]!=s2[n]){
		cout<<(int)(s1[m]-s2[n]);
		return 0;
	}
	m++,n++;
}
return 0;

}


评论:

请先登录,才能进行评论