GeekInterview.com
Answered Questions

We have two buckets, 1 of capacity 3liter and another of 5 liter.We have 5 liters of water.So how will we make combinations such that 1 bucket will have exactly 4 liters of water?

Asked By: sillysamal | Asked On: Feb 17th, 2007

Star Read Best Answer

Editorial / Best Answer

Answered by: anishkumar

Answered On : Feb 28th, 2007

First pour 5 liter of water in 3 liter container .... now you will have 2 liter remaning in 5 liter...now empty the 3 liter and fill it with 2 liter from the 5 lit container..... now take 5 liter and pour one more liter to 3 liter container ...now you are left with 4 liter in 5 liter container

     5         3
 
     5         0
     2         3
     2         0
     0         2
     5         2
     4         3

Answered by: sugins on: Apr 1st, 2012

1.Keep the 5lit bucket full and 3lit bucket empty. 2. Now pour water into the 3 lit bucket from the 5lit bucket and full it. 3.Now we will hav remaining 2lit of water in 5lit bucket and 3lit of water...

Answered by: Gopal27 on: Jan 28th, 2012

1. Fill 3lt bucket from 5lt (the left water is 2lt)
2. Fill 5lt from 3lt
3. Again fill 3lt from 2lt water
4. Then this 3lt bucket fill from 5lt bucket
5. As this we found 4lt water in 5lt bucket..

What is the main difference between portability and platform independent ?

Asked By: deepa | Asked On: May 22nd, 2006

Star Read Best Answer

Editorial / Best Answer

Answered by: Lecks

View all answers by Lecks

Member Since Feb-2010 | Answered On : Feb 21st, 2010

I agree it is correct to say that Java is platform independent, but it is due to the Java Virtual Machine. Java programs are only intermediately compiled, which allows adaptation to the given environment it needs to run in later.

An example of a portability issue is the creation of Unix. The first version was not portable. It was specific only to that computer's architecture. Unix became portable when it was rewritten in C. The new version written in C was portable because C served as a "translator", if you will, between what underlying architecture or devices were physically in the computer and what unix wanted them to do.

Answered by: Lecks on: Feb 21st, 2010

I agree it is correct to say that Java is platform independent, but it is due to the Java Virtual Machine. Java programs are only intermediately compiled, which allows adaptation to the give...

Answered by: akki21 on: Feb 21st, 2007

"portability" refers to the ability of a system to support a particular software.it depends on the system configurations.

"platform independent"
JAVA is a platform independent software. it need not be installed for the processing of its program

Interview Question

 Ask Interview Question?

 

Career Counselling

 Have Career Question?

 Ask Chandra

 Ask Only Career questions.

Follow us: