题解 | while
while
https://www.nowcoder.com/practice/173564fc07c146a88c408c92f4182c65
#include <cstddef>
#include <iostream>
using namespace std;
int main() {
string a;
cin >> a;
string target = "while";
size_t count = 0;
for(int i = 0; i<5; i++){
if(a[i] != target[i]) count++;
}
cout << count << endl;
}
// 64 位输出请用 printf("%lld")
查看10道真题和解析