#include <iostream>
#include <vector>
#include <stack>
using namespace std;
const int N = 1 + 5e4;
vector<int> graph[N];
stack<int> S;
bool use[N];
void dfs(int x){
use[x] = true;
for (int y : graph[x])
if ( !use[y] )
dfs(y);
S.push(x);
}
int main(){
freopen("sortaret.in", "r", stdin);
freopen("sortaret.out", "w", stdout);
int n, m, x, y;
cin >> n >> m;
while (m--){
cin >> x >> y;
graph[x].push_back(y);
}
for (int i = 1; i <= n; i++)
if ( !use[i] )
dfs(i);
while ( !S.empty() ){
cout << S.top() << ' ';
S.pop();
}
cout << '\n';
return 0;
}