#include <bits/stdc++.h>
using namespace std;
ifstream fin("sortaret.in");
ofstream fout("sortaret.out");
const int LMAX = 50005;
vector<int> L[LMAX], LT[LMAX];
int top[LMAX], idx = 1;
bool viz[LMAX];
void dfs(int node) {
viz[node] = 1;
for (int vec : LT[node]) {
if (!viz[vec]) {
dfs(vec);
}
}
top[idx] = node;
idx++;
}
int main(){
int n, m;
fin>>n>>m;
while (m--) {
int x, y;
fin>>x>>y;
L[x].push_back(y);
LT[y].push_back(x);
}
for (int i = 1; i <= n; i++) {
if (!viz[i]) dfs(i);
}
for (int i = 1; i <= n; i++) {
fout<<top[i]<<" ";
}
fin.close();
fout.close();
return 0;
}