#include<bits/stdc++.h>
using namespace std;
int main(){
	int a,b;
	scanf("%d %d",&a,&b);
	if(b>a){
		swap(b,a);
	}
	printf("%d %d",b,a);
	
}

/**************************************************************
	Problem: 1419
	User: zhengzihao3
	Language: C++
	Result: Accepted
	Time:8 ms
	Memory:2072 kb
****************************************************************/