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...

There are 2 empty jars of 5 and 3 liters capacity. And a
river is flowing besides. I want to measure 4 liters of
wanter using these 2 jars. How do you do this?

Answer Posted / harminder

I think i got got bit more simpler solnn with lesser steps

1. Fill 5 ltr jar, pour it intoo 3 ltr till its full
2. Now 3 ltr jar is full n 5 ltr jar has 3 ltrs in it.
3. Empty 3 ltr jar, and pour 2 ltr in 3 ltr jar,, now 4 ltr has 3 ltrs in it and 5 ltr jar is empty
4. Fill 5 ltr jar and out of the 5ltr jar shift water in 3 ltr jar, since only 1 ltr can be tranferred into 3 ltr jar,,
the 5 ltr jar has 4 ltr water in it..

*Hell the interviewer must have seen "Die Hard Part 2 - With a Vengeance" the previous night

Is This Answer Correct ?    3 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are objects in oop?

1041


How many human genes are polymorphic?

1003


Get me an image implementation program.

1941


What do you mean by overloading?

1026


What is encapsulation with example?

1027


Why can't we have instance(stack) of a class as a member of the same class like eg.Class A{A obj;} as we can have self refential pointer

2093


What is the use of oops?

996


What are the advantages of polymorphism?

978


write a programe to calculate the simple intrest and compund intrest using by function overlading

2133


What are two types of polymorphism?

1017


What is the difference between inheritance and polymorphism?

1051


hi all..i want to know oops concepts clearly can any1 explain??

2083


What is the difference between a constructor and a destructor?

1176


How can you overcome the diamond problem in inheritance?

1139


What are the benefits of oop?

1168