#include <iostream>
#include <fstream>
#include <vector>
#include <stack>
using namespace std;
ifstream fin("sortaret.in");
ofstream fout("sortaret.out");
int n, m;
vector<int> v[50005];
bool vizitat[50005];
stack<int> st;
void dfs(int x) {
vizitat[x] = true;
for (int y : v[x])
if (!vizitat[y])
dfs(y);
st.push(x);
}
int main() {
fin >> n >> m;
for (int i = 0; i < m; i++) {
int x, y;
fin >> x >> y;
v[x].push_back(y);
}
for (int i = 1; i <= n; i++)
if (!vizitat[i])
dfs(i);
while (!st.empty()) {
fout << st.top() << ' ';
st.pop();
}
fout << '\n';
return 0;
}