#include <stdio.h>
int main ()
{
int counter, largest, number,largest2,t;
counter = 1;
printf("请输入10个整数:");
scanf("%d", &number);
largest = number;
largest2 = number;
while (counter <= 9)
{
counter++;
printf("请输入10个整数:");
scanf("%d", &number);
if (largest < number)
{
t=largest;
largest = number;
largest2 = t;
}
}
printf("最大的两个数是%d\t%d\n", largest, largest2);
return 0;
}
int main ()
{
int counter, largest, number,largest2,t;
counter = 1;
printf("请输入10个整数:");
scanf("%d", &number);
largest = number;
largest2 = number;
while (counter <= 9)
{
counter++;
printf("请输入10个整数:");
scanf("%d", &number);
if (largest < number)
{
t=largest;
largest = number;
largest2 = t;
}
}
printf("最大的两个数是%d\t%d\n", largest, largest2);
return 0;
}