View Code of Problem 75

#include<cstdio>
#include<cstdlib>
#include<cmath>
#include<iostream>
#include<algorithm>
using namespace std;
int cmp(int a,int b)
{
		return a<b;
}
int main(){
    int a[10];
	for(int i=0;i<10;i++)
	{
			scanf("%d",&a[i]);
	}
	sort(a,a+10,cmp);
	for(int j=0;j<10;j++)
	{
			printf("%d\n",a[j]);
	}
	return 0;

}

Double click to view unformatted code.


Back to problem 75