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 / sonia
fill 5 liters jar and pour in 3 liters------ now you have 3 in 3 liters and 2 in 5 liters.
pour away the 3 in 3 liters jar and transfer the 2 in the now empty 3 liters.
Fill 5 liters jar again and pour in 3 liters jar----- Now you have 1 from 5 liters and 2 that were in 3 liters jar already. this gives you 4 in the 5 liters jar.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is persistence in oop?
What is difference between data abstraction and encapsulation?
How do you explain polymorphism?
What are different types of JVM's? for example we use dalvik jvm for android then what about the remaining operating systems?
What are the 3 principles of oop?
What makes a language oop?
What is encapsulation in oops?
Which language is pure oop?
What is the use of oops?
This program numbers the lines found in a text file. Write a program that reads text from a file and outputs each line preceded by a line number. Print the line number right-adjusted in a field of 3 spaces. Follow the line number with a colon, then one space, then the text of the line. You should get a character at a time and write code to ignore leading blanks on each line. You may assume that the lines are short enough to fit within a line on the screen. Otherwise, allow default printer or screen output behavior if the line is too long (i.e., wrap or truncate). A somewhat harder version determines the number of spaces needed in the field for the line numbers by counting lines before processing the lines of the file. This version of the program should insert a new line after the last complete word that will fit within a 72-character line.
Why is abstraction used?
can inline function declare in private part of class?
What is overloading and its types?
what is different between oops and c++
What is a class in oop?