View Code of Problem 75

#include<bits/stdc++.h>
using namespace std;
int main(){
	int a[10],t=0,i,j;
	for(i=0;i<10;i++)
	cin>>a[i];
	for(i=0;i<10;i++){
		for(j=0;j<10;j++){
			if(a[i]<a[j]){
				t=a[j];
				a[j]=a[i];
				a[i]=t;
			}
			
		}
	}
	for(i=0;i<10;i++)
	cout<<a[i]<<endl;
	return 0;
}

Double click to view unformatted code.


Back to problem 75