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 |
what is current plr rate of sbi
please i need help on getting hevron nigeria aptitude test questions.
simla pact was signed by
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?
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?
if the sum of five consecutive nos. 35? how many prime numbers are there :
if 2 miles of fence enclose a square plot of 160 acres,how large a square will 4 miles of fence
3,3,5,4,4,-,-,5,4,3, find the blanks of given series
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.
Five trays cost is 0.35 each and dozen-----