#include<stdio.h>
#include<string.h>
#define MAX 100
int main()
{
    int n;
    char sentence[MAX],words[50][MAX];
    int i=0,count=0;
    scanf("%d",&n);
    getchar();
    fgets(sentence,sizeof(sentence,"\n"),stdin);
    sentence[strcspn(sentence,"\n")]="\0";
    
    char*token=strtok(sentence,"");
    while(token!=NULL&&count<n)
    {
        strcpy(words[count++],token);
        token=strtok(NULL,"");
    }
    for(i=count-1;i>=0;i--)
    {
        printf("%s",words[i]);
        if(i>0){
        printf (" ");
        }
    }
    return 0;
}