We Post only the Best Stuff

Find Quotient as well as Remainder of 2 numbers

Previous Program »» Hello World Program in C

Here's the program to find out quotient as well as remainder from 2 numbers using C Language as your programming language

We assume something here:-


Here we have used the property of division i.e.
Dividend = (Divisor * Quotient) + Remiander
       a       = (      b     *         c    )  +        d
therefore,
Remiander = Dividend - (Divisor * Quotient)
       d         =        a      -  (    b     *        c       )

#include <stdio.h>
#include <conio.h>
void main()
{
clrscr();
int=a,b,c,d;
printf("Enter the Dividend and Divisor: ");
scanf("%d %d",&a,&b);
c=a/b;
printf("Quotient is = %d",c);
{
d=a-(b*c);
printf("Remiander is = %d",d);
}
getch();
}
Next Post »» C Program for Addition of 2 Numbers


For further Knowledge and Tutorial Keep Visiting :-
TechJatt - The source for all kind of Tutorial on Ethical Hacking

Like Us on Facebook or Follow on Twitter or Add to Circles on Google + to remain updated
Support : Contact Us | Privacy Policy | Site Map
Copyright © 2013. Tech Jatt - All Rights Reserved
Site Design by Nitin Kundu Licensed to Tech Jatt
Proudly powered by Blogger