#include <bits/stdc++.h>
using namespace std;
long n, m, u, v, label[100005];
long idx, cnt[100005];
vector<long> adj[100005];
priority_queue<long> pq;
int main() {
  scanf("%ld %ld", &n, &m);
  for (int i = 1; i <= m; i++) {
    scanf("%ld %ld", &u, &v);
    adj[v].push_back(u);
    cnt[u]++;
  }
  for (int i = 1; i <= n; i++) {
    if (cnt[i] == 0) {
      pq.push(i);
    }
  }
  idx = n;
  while (pq.size() > 0) {
    long u = pq.top();
    pq.pop();
    label[u] = idx;
    idx--;
    for (int v : adj[u]) {
      cnt[v]--;
      if (cnt[v] == 0) {
        pq.push(v);
      }
    }
  }
  for (int i = 1; i <= n; i++) {
    printf("%ld ", label[i]);
  }
}
