rev='made'/> name='keywords'/> name='author'/> ANURANAN: UVa Solution 11462 : Age Sort

Welcome Note

Anisuzzaman Babla

Software Engineer at D Money Bangladesh Limited

I am an enthusiastic Android developer and interested in the newest technologies and trends. I have in total over five years of active Android development experience. I have worked on numerous projects used by hundreds of thousands of people. Moreover, 5+ of commercially successful apps are live at Google play store made by me.

I am eager to learn new things everyday. At the moment, my focus is on the new Java 8 and 9 language features, RxJava and RxAndroid, Kotlin, architectural patterns on Android (MVVM, MVP, etc.) and of course I am always up for trying out the newest Android libraries.

UVa Solution 11462 : Age Sort

#include<algorithm>
#include<stdio.h>
using namespace std;
long int a[2000005],i,n;
int main()
{
    while (scanf("%ld",&n)!=EOF)
    {
        if (n==0)
        {
            break;
        }
        for (i=0;i<n;i++)
        {
            scanf("%ld",&a[i]);
        }
        sort(a,a+n);
        for (i=0;i<n;i++)
        {
            printf("%ld",a[i]);
            if (i<(n-1))
                printf(" ");
        }
        printf("\n");
    }
    return 0;
}