#include <bits/stdc++.h>
using namespace std;
const int maxn = 100007;
int n, m, du[maxn], a[maxn], cnt;
vector<int> G[maxn];
bool inq[maxn];
priority_queue<int> q;
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= m; i++) {
    static int u, v;
    scanf("%d%d", &u, &v);
    G[v].push_back(u);
    du[u]++;
  }
  cnt = n;
  for (int i = 1; i <= n; i++) {
    if (du[i] == 0) {
      inq[i] = true;
      q.push(i);
    }
  }
  while (!q.empty()) {
    static int p;
    p = q.top();
    q.pop();
    a[p] = cnt--;
    for (int i = 0; i < G[p].size(); i++) {
      static int t;
      t = G[p][i];
      if (!inq[t]) {
        du[t]--;
        if (du[t] == 0) {
          q.push(t);
          inq[t] = true;
        }
      }
    }
  }
  for (int i = 1; i <= n; i++) printf("%d ", a[i]);
  puts("");
  return 0;
}
