0分求助
查看原帖
0分求助
1360496
NullPointerExpection楼主2024/7/28 12:16
#include <bits/stdc++.h>
using namespace std;

char x, z;
long long y, w;
int main() {
	cin >> x >> y >> z >> w;
	if(x == z && x >= 'a' && x <= 'z') {
		cout << "vaild\n";
		if(y <= w)
			cout << w - y + 1;
		else
			cout << y - w + 1;
	}
	else
		cout << "Invaild\n-1";
	return 0;
}
2024/7/28 12:16
加载中...