Close Program! but why?

Jan 27, 2013 at 4:58am
#include<stdio.h>
#include<conio.h>
int main()
{
int x,y,z;
printf("Input 3 numbers: ");
scanf("%d %d %d",x,y,z);

if((x>y)&&(y>z))
printf("The ascending order is %d, %d, %d/n The decendinding order is %d, %d, %d",z,y,x,x,y,z);

if((x>z)&&(z>y))
printf("The ascending order is %d, %d, %d/n The decendinding order is %d, %d, %d",y,z,x,x,z,y);

if((y>x)&&(x>z))
printf("The ascending order is %d, %d, %d/n The decendinding order is %d, %d, %d",z,x,y,y,x,z);

if((y>z)&&(z>x))
printf("The ascending order is %d, %d, %d/n The decendinding order is %d, %d, %d",x,z,y,y,z,x);

if((z>x)&&(x>y))
printf("The ascending order is %d, %d, %d/n The decendinding order is %d, %d, %d",y,x,z,z,x,y);

if((z>y)&&(y>x))
printf("The ascending order is %d, %d, %d/n The decendinding order is %d, %d, %d",x,y,z,z,x,y);

getch();
return 0;
}
Jan 27, 2013 at 5:07am
I'm not sure what you're asking.
Jan 27, 2013 at 7:17am
change
 
    scanf("%d %d %d",x,y,z);

to
 
     scanf("%d %d %d",&x,&y,&z);

Jan 27, 2013 at 7:26am
Close Program! but why?

no error message? btw, what's your compiler?
Jan 30, 2013 at 3:27pm
its okay now thanks Zhuge

chipp:devC++
Topic archived. No new replies allowed.