import java.util.*; public class _1766 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(), M = sc.nextInt(); int[] indegree = new int[N+1]; @SuppressWarnings("unchecked") ArrayList[] graph = new ArrayList[N+1]; for(int i=0; i<=N; i++) graph[i] = new ArrayList<>(); for(int i=0; i pq = new PriorityQueue<>(); for(int i=1; i<=N; i++) if(indegree[i] == 0) pq.add(i); ArrayList ans = new ArrayList<>(); while(!pq.isEmpty()) { int now = pq.poll(); ans.add(now); for (int next : graph[now]) { indegree[next]--; if(indegree[next] == 0) pq.add(next); } } for (int n : ans) { System.out.printf("%d ",n); } } }