#include <bits/stdc++.h>
using namespace std;
const int N = 5e4 + 1;
int n, m, x, y;
vector<int> mc[N], topsort;
bool vis[N];
void dfs(int nod)
{
vis[nod] = 1;
for (auto i : mc[nod])
{
if (!vis[i])
dfs(i);
topsort.push_back(i);
}
}
int main()
{
freopen("sortaret.in", "r", stdin);
freopen("sortaret.out", "w", stdout);
ios::sync_with_stdio(false);
cin.tie(0);
cin >> n >> m;
for (int i = 1; i <= m; ++i)
{
cin >> x >> y;
mc[x].push_back(y);
}
for (int i = 1; i <= n; ++i)
{
if (!vis[i])
{
dfs(i);
topsort.push_back(i);
}
}
reverse(topsort.begin(), topsort.end());
for (auto i : topsort)
cout << i << ' ';
return 0;
}