Tuesday, October 27, 2015

Find Reminder & Quotient in C - Working Code

#include<stdio.h>
#include<conio.h>
void main()
{
   int dividend, divisor, quotient, remainder;
   clrscr();
   printf("Enter the Dividend: ");
   scanf("%d", &dividend);
   printf("Enter the divisor: ");
   scanf("%d", &divisor);
   quotient = dividend/divisor;
   remainder = dividend%divisor;
   printf("Quotient: %d\n",quotient);
   printf("Remainder: %d",remainder);
   getch();
}


To Compile Press Alt+f9 
To Run Press Ctrl+f9

Output:


No comments:

Post a Comment