#include <iostream>
#include <fstream>
using namespace std;
int main()
{
ifstream in;
in.open("football.ppm");
ofstream out;
out.open("football_noRed.ppm");
string header;
int cols, rows, colors;
int r, g, b;
in >> header >> cols >> rows >> colors;
out << header << endl;
out << cols << " " << rows << endl;
out << colors << endl;
for (int i=0; i<rows; i++) {
for (int j=0; j<cols; j++) {
in >> r >> g >> b;
r = 0;
cout << r << " " << g << " "<< b << endl;
}
out << endl;
}
in.close();
return 0;
}