import java.io.*;
import java.util.*;
public class Main {
public static void main(String[] args) throws IOException {
BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
StringTokenizer st=new StringTokenizer(br.readLine());
int n=Integer.parseInt(st.nextToken());
int m=Integer.parseInt(st.nextToken());
int[] pre=new int[n+1];
int[] v=new int[n+1];
ArrayList<Integer>[] post=new ArrayList[n+1];
for(int i=1;i<n+1;i++)post[i]=new ArrayList<>();
ArrayList<Integer> ans=new ArrayList<>();
for(int i=0;i<m;i++){
st=new StringTokenizer(br.readLine());
int a=Integer.parseInt(st.nextToken());
int b=Integer.parseInt(st.nextToken());
pre[b]++;
post[a].add(b);
}
while(ans.size()!=n){
for(int i=1;i<n+1;i++){
if(v[i]==0 && pre[i]==0){
v[i]=1;
ans.add(i);
for(int a:post[i])pre[a]--;
}
}
}
BufferedWriter bw=new BufferedWriter(new OutputStreamWriter(System.out));
for(int a:ans)bw.write(a+" ");
bw.flush();
}
}
#위상정렬