#include<bits/stdc++.h>
using namespace std;
string rec;
string zabranjena_rec;
int brojac=0;
int main ()
{
  getline(cin, rec);
  getline(cin, zabranjena_rec);
  for(int i=0; i < rec.length(); i++)
  {
    if(rec[i]=='a')
    {
      rec[i]='*';
      brojac++;
    }
  }
  cout << brojac << endl << rec;
  return 0;
}