#include <fstream>
#include <algorithm>
#include <cmath>
#include <iomanip>
#include <stack>
#include <iostream>
#include <vector>
#include <string>

#define pb push_back

using namespace std;
using ll = long long;
using ull = unsigned long long;
using dl = double;

const ll N = 405 * 405;
const ll inf = 100000000000;

ifstream in("input.txt");
ofstream out("output.txt");

int n, m;
int a[N];
int b[405][405];
vector<int> g[405], h[405];

int main() {

    in >> n >> m;

    int k = 0;
    int inp;
    for (int i = 0; i < n; ++i) {
        for (int j = 0; j < m; ++j) {
            in >> inp;
            a[k++] = inp;
            b[i][j] = inp;
        }
    }

    for (int i = 0; i < n; ++i) {
        for (int j = 0; j < m; ++j) {
            for (int l = 0; l < m; ++l) {
                if (l >= j) break;
                if (b[i][j] == b[i][l]) {
                    out << "+" << endl;
                }
            }
        }
    }



    return 0;
}