#include <fstream>
#include <queue>
#include <vector>
std::ifstream fin("sortaret.in");
std::ofstream fout("sortaret.out");
static int const NMAX = 50000;
int n;
std::vector<std::vector<int>> graph;
std::vector<int> int_deg;
std::vector<int> topsort() {
std::vector<int> ans;
std::queue<int> queue;
for (int i = 1; i <= n; i++) {
if (int_deg[i] == 0) {
queue.push(i);
}
}
while (!queue.empty()) {
int curr = queue.front();
queue.pop();
ans.push_back(curr);
for (int neigh : graph[curr]) {
int_deg[neigh]--;
if (int_deg[neigh] == 0) {
queue.push(neigh);
}
}
}
return ans;
}
int main() {
int m;
fin >> n >> m;
graph.assign(n + 1, std::vector<int>());
int_deg.assign(n + 1, 0);
for (int i = 0; i < m; i++) {
int x, y;
fin >> x >> y;
graph[x].push_back(y);
int_deg[y]++;
}
std::vector<int> ans = topsort();
for (int node : ans) {
fout << node << ' ';
}
}