Thursday 31 March 2016

Binary Logic

Binary Logic

Binary Logic questions are an important type which frequently appear in IT company entrances and MBA entrance exams.  In these problems, you find people answer a questions in two or three different statements and some of them are true and some are false. Based on the clues given, we have to figure out the actual category of persons.


Solved Example 1:
Three persons give these statements.
A says either Democratic or Liberal wins the elections.
B says Democratic wins.
C says neither Democratic nor Liberal wins the elections.
Of these statements only one is wrong. Who wins the elections?
As only one statement is wrong, other two statements will be true.
Assume Democratic wins the election. Now Statements of A and B are true.  Which satisfies our condition that 2 of them are truth tellers. So Democratic wins the election
If you assume Liberal wins the election,Statements of B and C are becoming false which is against our condition.

Note: Most of the binary logic questions can be solved easily if you start assuming like above. 

Solved Example 2:
Consider the following statements:
Albert:  Dave did it.
Dave :   Tony did it.
Gul:        I did not do it.
Tony:     Dave lied when he said that  I did it.
(a) If only one out of all above statements is true, who did it?
(b) if only one out of all above statements is false, who did it?

We solve this question by assuming that Albert is thief.  Then Dave, there after Gul. and put it in a table



From the table, it is clear that only one statement is false when we assume Dave is thief. So answer for (b) is Dave. And only one statement became true, when we assume Gul is thief. So answer for (a) is Gul

Solved Example 3:
The police rounded up Jim, Bud and Sam yesterday because one of them was suspected of having robbed the local bank. The three suspects made the following statements under intensive questioning.
Jim : I’m innocent.
Bud: I’m innocent.
Sam: Bud is the guilty one.
If only one of the statements turned out to be true, who robbed the bank?
Assume Jim is the thief. Now Except Bud statement, remaining two statements became false which is given in the question. So Jim is the thief.

Solved Example 4:
Directions : Three criminals were arrested for shop lifting. However, when interrogated only one told the truth in both his statements, while the other two each told one true statement and one lie. The statement were:

ALBERT: (a) Clive passed the goods.
          (b) Bruce created the diversion.
BRUCE : (a) Albert passed the goods.
          (b) I created the diversion.
CLIVE :    (a) I took the goods out of the shop.
          (b) Bruce passed goods.

Who created the diversion?
(a) Albert (b) Clive
(c) Bruce (d) either (a) or (c)
(e) either (b) or (c)

Solved Example 5:
Using the data from the above question, which of these statements is correct?
(a) Clive created the diversion.
(b) Albert took the goods out of the shop.
(c) Clive passed the goods.
(d) Albert created the diversion.
(e) Albert passed the goods.
Let ‘T’ represents true statement and ‘F’ represents false statement.
We have to check possibilities and contradictions by assuming one person speaking truth and others will say truth or lie alternatively.
Assuming Bruce to speak truth

Above mentioned possibility satisfies the conditions as others give contradictions.
So, Albert passed the goods.
Bruce created diversion.
Clive took goods out of shop.

Solved Example 6:
Directions:  On an Island there live three types of tribes Sachcha, Jhutha and Lota. Sachchas always tell the truth, Jhuthas always lie and Lotas tell the truth and lie alternating (they can tell truth first or lie first). Three persons (of different tribes) from this Island give these statements.
GOOD: UGLY is of Sachcha tribe: I am of Lota tribe
BAD : GOOD is of Jhutha tribe; I am of Sachcha Tribe
UGLY: BAD is of Jhutha tribe; I am of Lota tribe.

GOOD belongs which tribe?
(a) Sachcha 
(b) Jhutha
(c) Lota 
(d) either (a) or (c)
(e) Cannot say
If we assume Good is of Sachcha tribe person, His both statements should be true. But one of his statement Ugly is of sachcha tribe should be wrong as there is only one shachcha tribe person.
Now assume BAD is of sacha tribe person. Now his second statement is obviously true and His first statement indicates that Good is of Jutha type which implies that Ugly is of Lota type.  Now checking of the truthfullness of the statements of Good and Ugly, we get Good's both the statements are wrong and Ugly's one statements is correct and one is wrong. So Good Belong to Jutha tribe.

Solved Example 7:
Directions: Chatia, Matia and Toni participated in a race and on of them won the race. They belong to three different communities - Sororian, Nororian and Cororian. Sororians always speak the truth, Nororians always lie and Cororians always tell the truth and lie alternatively. (Each of Chatia, Matia and Toni belongs to one community.)
After the race they gave these statements.
Chatia: 1. I would have won the race if Toni had not obstructed me at the last moment.
      2. Toni always speaks the truth.
      3. Toni is the winner.
Matia:   1. Chatia won the race.
             2. Toni is not a Nororian.
Toni:    1. I hadn’t obstructed Chatia at the last moment.
             2. Matia won the race.

 Toni belongs to which community?
(a) Sororian (b) Nororian
(c) Cororian (d) Either b or c
(e) Cannot say

Solved Example 8:
Who won the race?
(a) Matia 
(b) Toni
(c) Sororian 
(d) Chatia
(e) Cannot say
Sol: Assume Matia is truth teller So he is a Sororian. Then chatia is the winner and Toni is Cororian (Alternator) Which implies Chatia is a false sayer (Nororian)
If we check the truthfullness of the Chatia, We get his all statements are wrong and Toni's one statement is wrong.
So Toni belongs to Cororian and Chatia won the race

Tuesday 29 March 2016

Cubes

Cubes


A cube is a 3-dimensional diagram with all sides equal.  If we divide it into the size (1n)th   part of its side, we get n3smaller cubes.
Shown below is a cube which is painted on all the sides and the cut into (14)th of its original side.


Some observations: A cube has 6 faces, 12 edges and 8 corners. We can see that the cubes which got all the three sides painting lies at the corners. So the number of cubes which got painted all the three sides is equal to 8. Cubes with 2 sides painting lie on the edges (see the diagram). But the cubes which are on the left and right side of the edge matches with the corners. So we have to substract these two cubes from the number of cubes lying on the edge to get the number of cubes with 2 sides painting. Cubes with 1 side painting lies on the surfaces. Since, the top row, bottom row, left column, and right column matches with the edges, We must exclude these cubes while calculating the single side painted cubes.

The following rules may be helpful: If a cube is divided into the size (1n)th of its original side after get painted all the sides, Then

Total number of cubes = n3
Cubes with 3 sides painting = 8
Cubes with 2 sides painting = 12×(n2)
Cubes with 1 sied painting = 6×(n2)2
Cubes with no painting = (n2)3
Solved Examples (Level - 1)

1. A cube whose two adjacent faces are coloured is cut into 64 identical small cubes. How many of these small cubes are not coloured at all?
Assume the top face of the cube and its right side are colored green and orange respectively.


Now If we remove the colored faces, we left with a cuboid, whose front face is indicated with dots.


So on the front face there are 9 cubes, and behind it lies 4 stacks.  So total 9 x 4 = 36


2. A cube, painted yellow on all-faces is cut into 27 small cubes of equal size. How many small cubes got no painting?


Assume we have taken out the front 9 cubes.  Then the cube looks like the one below.

Now the cube which is in the middle has not got any painting.  The cubes on the Top row, bottom row, left column and right column all got painting on atleast one face.

Alternative method:

Use formula: (n2)3  Here n = 3 So (32)3 = 1


3.  All surfaces of a cube are coloured. If a number of smaller cubes are taken out from it, each side 1/4 the size of the original cube's side, Find the number of cubes with only one side painted.


The original (coloured) cube is divided into 64 smaller cubes as shown in the figure.  The four central cubes on each face of the larger cube, have only one side painted.  Since, there are six faces, therefore total number of such cubes = 4 x 6 = 24.

Alternative Method:

Use formula : 6×(n2)2 = 6×(42)2 = 24
Level - 2

4. Directions: One hundred and twenty-five cubes of the same size are arranged in the form of a cube on a table. Then a column of five cubes is removed from each of the four corners. All the exposed faces of the rest of the solid (except the face touching the table) are coloured red. Now, answer these questions based on the above statement:
(1) How many small cubes are there in the solid after the removal of the columns?
(2) How many cubes do not have any coloured face?
(3) How many cubes have only one red face each?
(4) How many cubes have two coloured faces each?
(5) How many cubes have more than 3 coloured faces each?
The following figure shows the arrangement of 125 cubes to form a single cube followed by the removal of 4 columns of five cubes each.


When the corner columns of the original cube are removed , and the resulting block is coloured on all the exposed faces (except the base) then we get the right hand side diagram.  We labelled the various columns from a to u as shown in the figure

(1): Since out of 125 total number of cubes, we removed 4 columns of 5 cubes each, the remaining number of cubes = 125 - (4 x 5) = 125 - 20 = 105.
(2): Cubes with no painting lie in the middle.  So cubes which are blow the cubes named as s, t, u, p, q, r, m, n, o got no painting.    Since there are 4 rown below the top layer, total cubes with no painting are (9 x 4) = 36.
(3): There are 9 cubes namaed as m, n, o, p, q, r, s, t and u in layer 1, and 4 cubes (in columns b, e, h and k) in each of the layers 2, 3, 4 and 5 got  one red face. Thus, there are 9 + (4 x 4) = 25 cuebs.
(4)  the columns (a, c, d, f, g, i, j, l) each got 4 cubes in the layers 2, 3, 4, 5.  Also in the layer 1, h, k, b, e cubes got 2 faces coloured.  so total cubes are 32 + 4 = 36
(5): There is no cube in the block having more than three coloured faces. There are 8 cubes (in the columns a, c, d, f, g, i, j and l) in layer 1 which have 3 coloured faces. Thus, there are 8 such cubes.
Thus, there are 8 such cubes.

5. Directions: A cube of side 10 cm is coloured red with a 2 cm wide green strip along all the sides on all the faces. The cube is cut into 125 smaller cubes of equal size. Answer the following questions based on this statement:
(1) How many cubes have three green faces each?
(2) How many cubes have one face red and an adjacent face green?
(3) How many cubes have at least one face coloured?
(4) How many cubes have at least two green faces each?
Clearly, upon colouring the cube as stated and then cutting it into 125 smaller cubes of equal size we get a stack of cubes as shown in the following figure.



The figure can be analysed by assuming the stack to be composed of 5 horizontal layers.
(1): All the corner cubes are painted green.  So there are 8 cubes with 3 sides painted green.
(2): There is no cube having one face red and an adjacent face green as all the green painted cubes got paint on atleast 2 faces.
(3): Let us calculate the number of cubes with no painting.  By formula,  (n2)3 = (52)3 =  27
Therefore, there are 125 - 27 = 98 cubes having at least one face coloured.
(4): From the total cubes, Let us substract the cubes with red painting, cubes with no painting.
125 - (9 x 6) - 27 = 44