برچسب‌ها

۱۳۸۸ آذر ۲۱, شنبه

برنامه ایکه 3 عدد را دریافت و مشخص میکند کدام بزرگتر و چندمین عدد است

int main()
{float a,b,c;
printf("pleas isert 3 number to compare :");
printf("insert a :");
scanf("%f",&a);
printf("insert b :");
scanf("%f",&b);
printf("insert c :");
scanf("%f",&c);
if(a>c && a>b)
printf("the large number is the first one (a)");
if(c>a && c>b)
printf("the large number is the third one (c)");
if(b>a && b>c)
printf("the large number is the second one (b)");
getch();
}

هیچ نظری موجود نیست:

ارسال یک نظر