Untitled

mail@pastecode.io avatar
unknown
plain_text
7 months ago
506 B
1
Indexable
Never
#include<stdio.h>
int main()
{
    int a[1010],n,i,lowest,count=0;
    scanf("%d",&n);

    for(i=0 ; i<n ; i++)
    {
        scanf("%d",&a[i]);
    }
    lowest = a[0];
    for(i=0 ; i<n ; i++)
    {
        if(a[i] < lowest)
        {
            lowest = a[i];
        }
        if(a[i] == lowest)
        {
            count++;
        }
    }
    if(count % 2 != 0)
    {
        printf("Lucky\n");
    }
    else
    {
       printf("Unlucky\n");
    }
    return 0;
}