#include<stdio.h>
int main()
{
int anik[100], i, max, k;
for(i=0; i<100; i++)
{
scanf("%d", &anik[i]);
}
max = anik[0];
for(i=1; i<100; i++)
{
if(max < anik[i])
{
max = anik[i];
k = i;
}
}
printf("%d\n",max);
printf("%d\n",k+1);
return 0;
}
int main()
{
int anik[100], i, max, k;
for(i=0; i<100; i++)
{
scanf("%d", &anik[i]);
}
max = anik[0];
for(i=1; i<100; i++)
{
if(max < anik[i])
{
max = anik[i];
k = i;
}
}
printf("%d\n",max);
printf("%d\n",k+1);
return 0;
}
Comments
Post a Comment