A C++ program to calculate the quotient and reminder of a given dividend and divisor.

#include<iostream>
#include<conio.h>
using namespace std;
main()
{
int dividend,divisor,quotient,reminder;

cout<<"Enter dividend : ";

cin>>dividend;

cout<<"Enter dividend : ";

cin>>divisor;

quotient = dividend/divisor;

reminder = dividend%divisor;

cout<<"Quotient = "<<quotient<<endl;

cout<<"reminder = "<<reminder;

return 0;
}

Output:

Enter dividend : 20
Enter dividend : 3
Quotient = 6
reminder = 2