a group of friends goes for dinner and gets bill of Rs 2400
. Two of them says that they have forgotten their purse so
remaining make an extra contribution of Rs 100 to pay up
the bill. Tell the no. of person in that group

Let 'x' be the number of perons in the group and let 'y' be
amount per head which they have to pay.
Then xy = 2400.
or y = 2400/x
Since two friends have forget the purse, x-2 persons should
share the total amount(2400).
If they share, they have to make an extra contribution of
Rs 100 to pay up the bill
That is x-2 persons should pay y+100 each
or (x-2)(y+100) = 2400
or y+100 = 2400/(x-2)
or y = 2400/(x-2) - 100
Therefore we have got two equations namely,
y= 2400/x and y = 2400/(x-2) - 100
Comparing these two, we get
2400/x = 2400/(x-2) - 100
Solving this we get
x^2 - 2x -48 = 0
or (x-8) (x+6) = 0
or x = 8 or x = -6
Since 'x' denote the number of persons, it should be
positive.
So, x = 8.

let the no.of persons=x
then
100(x-2)+(x-2)*2400/x=2400
100x-200x+(2400x-4800)/x=2400
.
.
.
.
==> (x-8)=0 or (x+6)=0
finally either x=8 or -6
therefore the no.of persons = 8

suppose 8 person goes for dinner and gets bill of 2400
each person gets 300
8*300=2400
two of them forgotten purse
then
8-2=6
6*300=1800
extra contribution 100 of 6 person
6*100=600

in an cricket match the team has to score 8 runs from 3
balls,the crickets on the grease were at a:92;b:96,they
must complete hundred in the match how?

Ques--Input a number and then find the next higher number
such that for both the number (inputted and the next higher
number)
in binary representation contains equal number os ones.
Example:
Input:3(0000000000000011)
Ouput:5(0000000000000101)
I want a solution in C/C++ language

By selling 1 dozen ball pens, a shopkeeper earned the profit
equal the profit equal to the selling price of 4 ball pens.
His profit percent is?
a)50 b)40 c)33 1/3 d)31 1/4
plz specify reason... thanks

A car is filled with 4.5 gallons of fuel for a round trip .
Car is taken 1/4 more than in going than coming up. What is
the fuel consumed in coming up ?