Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to find remainder of two numbers without using (%)
operator



How to find remainder of two numbers without using (%) operator..

Answer / shubham

using formula "Dividend = Quotient x Divisor + Remainder"
the c++ code for this would be

#include<iostream.h>
void main()
{
int a,b,q,r;
cout<<"Enter a ";
cin>>a;
cout<<"Enter b ";
cin>>b;
q=a/b;
r=a-q*b;
cout<<"Remender="<<r;
}

Is This Answer Correct ?    16 Yes 1 No

Post New Answer

More General Aptitude Interview Questions

what is current plr rate of sbi

2 Answers  


please i need help on getting hevron nigeria aptitude test questions.

0 Answers  


simla pact was signed by

1 Answers   SSC,


The ratio of the number of boys and girls in a school is 3:2 Out of these 10% the boys and 25% of girls are scholarship holders. % of students who are not scholarship holders.?

0 Answers   3i Infotech, Amazon, Canara Bank, Mu Sigma,


1. 2 containers labeled A and B are filled with red and blue marbles in given quantities: - Container RED BLUE A 6 4 B 60 40 Each container is shaken vigorously. After choosing 1 of the container, without looking, draw out a marble. From which container you have the max probability of choosing a blue marble?

2 Answers  


One of the longest sides of the triangle is 20 m. The other side is 10 m. Area of the triangle is 80 m2m2. What is the another side of the triangle?

0 Answers   Infosys,


if the sum of five consecutive nos. 35? how many prime numbers are there :

0 Answers   Verifone,


if 2 miles of fence enclose a square plot of 160 acres,how large a square will 4 miles of fence

2 Answers  


3,3,5,4,4,-,-,5,4,3, find the blanks of given series

6 Answers  


If there are 1024*1280 pixels on a screen and each pixel can have around 16 million colors Find the memory required for this?

0 Answers   3i Infotech, Canara Bank, EDS,


Age of Grandfather is the ages of 4 grandchildren where their ages are in consecutive.Find the age of Grandfather.

0 Answers   IBM,


Five trays cost is 0.35 each and dozen-----

0 Answers   Ramco,


Categories