danesh
Full Member level 3
Hi guys,
hw to write a error detection code for condition where a variable is declared as int and user inputed mayb a non integer input ie. char
for example :
int b;
printf ("enter num!\n");
scanf("%ld",&b);
hw do we write a code so error msg could be flaged whenever user input non int values.
thanks....
hw to write a error detection code for condition where a variable is declared as int and user inputed mayb a non integer input ie. char
for example :
int b;
printf ("enter num!\n");
scanf("%ld",&b);
hw do we write a code so error msg could be flaged whenever user input non int values.
thanks....