Using integer variables : division

, by Prashant Gunjal


 C program for integer Division


#include<stdio.h>
 void main()
 {
int no1,no2,res;
clrscr();
printf("\n\t Enter no 1:");
scanf("%d",&no1);
printf("\n\t Enter no 2:");
scanf("%d",&no2);
res = no1 / no2;
printf("\n\tResultant division =  %d",res);
  getch();
}

OUTPUT : 

0 comments: