#include <cstdio>
#include <algorithm>
#include <iostream>
using namespace std;
int main(){
int n, l, r;
scanf("%d%d%d", &n, &l, &r);
int a[n];
for (int i = 0; i < n; i ++ )
scanf("%d", &a[i]);
sort(a + l,a + r + 1);
for (int i = 0; i < n; i ++ )
printf("%d ", a[i]);
return 0;
}