返回列表 發帖
  1. #include<bits/stdc++.h>
  2. using namespace std;
  3. int main()
  4. {
  5.     cin.tie(0);
  6.     cin.sync_with_stdio(0);
  7.     ifstream ifs;
  8.     ifs.open("read.txt");
  9.     ofstream ofs;
  10.     ofs.open("write.txt");

  11.     string str;
  12.     getline(ifs,str);
  13.     for(int i=0;i<str.length();i++)
  14.     {
  15.         if(str[i]!='*')
  16.         {
  17.             ofs<<str[i];
  18.         }
  19.     }
  20.     return 0;
  21. }
複製代碼

TOP

返回列表