#include<iostream> #include<cstring> int main() { using namespace std; char word[5] = "?ate"; for(char ch = 'a';strcmp(word,"mate");ch++){ cout << word << endl; word[0] = ch; } cout << "After loop ends, word is " << word << endl; return 0; }
Sample 5.11:comstr1.cpp
最新推荐文章于 2022-03-25 15:33:26 发布