#include<bits/stdc++.h> using namespace std; int main() { string str; while (getline(cin,str)){ string str1 = str; transform(str.begin(),str.end(),str1.begin(),::tolower); if(str1.find("salt") != -1) cout<< str <<endl; } } |
Double click to view unformatted code.