#include <stdio.h>
void sort(int *x,int *y);
void swap(int *a,int *b);
int main(void) {
int x,y;
sort(&x,&y);
printf("降順に並び替えるとx=%d,y=%d",x
,y
);
return 0;
}
void sort (int *x,int *y){
if(*x<*y){
swap(x,y);
}
}
void swap(int *a,int *b){
int w;
w = *a;
*a = *b;
*b = w;
}
I2luY2x1ZGUgPHN0ZGlvLmg+Cgp2b2lkIHNvcnQoaW50ICp4LGludCAqeSk7CnZvaWQgc3dhcChpbnQgKmEsaW50ICpiKTsKCmludCBtYWluKHZvaWQpIHsKCWludCB4LHk7CgkKCXNjYW5mKCIlZCIsJngpO3ByaW50ZigieDolZFxuIix4KTsKCXNjYW5mKCIlZCIsJnkpO3ByaW50ZigieTolZFxuIix5KTsKCQoJc29ydCgmeCwmeSk7CgkKCXByaW50Zigi6ZmN6aCG44Gr5Lim44Gz5pu/44GI44KL44GoeD0lZCx5PSVkIix4LHkpOwoJCglyZXR1cm4gMDsKfQoKdm9pZCBzb3J0IChpbnQgKngsaW50ICp5KXsKCWlmKCp4PCp5KXsKCQlzd2FwKHgseSk7Cgl9Cn0KCnZvaWQgc3dhcChpbnQgKmEsaW50ICpiKXsKCWludCB3OwoJCgl3ID0gKmE7CgkqYSA9ICpiOwoJKmIgPSB3Owp9Cg==