General Aptitude

Assembling and grouping

Part 1 of 2 · 16 min

Assembling pieces into a shape

The concept

Start with something familiar

Think of laying tiles on a bathroom floor. Before you start, you check two things: do you have enough tiles to cover the floor, and will they fit without cutting? Plenty of tiles is no good if the last gap is the wrong shape.
GATE's assembling questions are the same check. You're shown a target shape and some pieces, and you must say which set of pieces can form it exactly, with no gaps and no overlaps. Most wrong options fail one quick test. Running the tests in the right order lets you throw them out in seconds, often without trying a single arrangement.
All the pieces here are made of unit squares, like tiles. A piece may be turned or flipped over unless the question says otherwise. To describe a placement without a picture, we draw the target as a grid and write each piece's letter in the squares it covers.

Idea 1: the areas must add up exactly

If the pieces cover the target with no gaps and no overlaps, then the area of the pieces is the area of the target. That's the first and fastest test:sum of piece areas=target area\text{sum of piece areas} = \text{target area}
TargetPiecesTotalPossible?
4 by 4 (16)5, 4, 4, 316maybe
4 by 4 (16)5, 4, 4, 417no
3 by 5 (15)4, 4, 412no
Example
Can pieces of 5, 5, 4 and 3 unit squares form a 4 by 4 square?
5+5+4+3=175 + 5 + 4 + 3 = 17, but the square has 16 squares. One square would have to overlap, so no.

Idea 2: lengths must fit, and every row must be fillable

A piece can't be longer than the target in any direction, however you turn it. So a straight 1 by 5 strip can never sit inside a 4 by 4 square.
A sharper version looks at a single row. Each piece covers some number of squares in each row it touches. If every piece covers an even number of squares in any row (as a 2 by 2 square does: 2 or 0), then a row with an odd number of squares can never be filled.
Example
Can six 2 by 2 squares cover a 5 by 5 grid with one corner square removed?
Area: 6×4=24=25−16 \times 4 = 24 = 25 - 1, so area is fine. But the row on the side away from the missing corner still has all 5 squares, and each 2 by 2 piece covers 0 or 2 squares of any row. You can't make 5 from 2s, so no.

Idea 3: colour the grid like a chessboard and count both colours

Colour the target's squares black and white like a chessboard. A domino (a 1 by 2 piece) always covers one black and one white square, wherever you put it. So a region can be covered by dominoes only if it has the same number of black and white squares.
The famous example: an 8 by 8 board with two opposite corners removed has 62 squares, so area allows 31 dominoes. But opposite corners are the same colour, so the board is left with 30 of one colour and 32 of the other. Each domino needs one of each, so no arrangement can ever work.
Picture it

30 dark·32 light

Other pieces have colour fingerprints too:
PieceSquaresColours
Domino 1 by 221 and 1
2 by 2 square42 and 2
T of 4 squares43 and 1
Straight 1 by 332 and 1
Example
Can three T-shaped pieces of 4 squares form a 3 by 4 rectangle?
A 3 by 4 rectangle has 6 black and 6 white squares, a difference of 0. Each T covers 3 of one colour and 1 of the other, a difference of 2 one way or the other. Three differences of ±2\pm 2 add to ±2\pm 2 or ±6\pm 6, never 0. So no, even though the area is right.

Idea 4: the missing piece is the target minus what's already placed

Many questions show a target with some pieces already in place and ask which piece fills the rest. Don't try the options one by one. Mark the covered squares, and the empty squares are the missing piece. Then just match its shape.
Here is a 4 by 4 square with three pieces placed. Rows 1 to 4 run from top to bottom, and a dot means empty.
c1c2c3c4
AAAB
CABB
CC·B
C···
The empty squares are (3,3)(3, 3), (4,2)(4, 2), (4,3)(4, 3) and (4,4)(4, 4): a row of three along the bottom with one square sticking up from the middle. That's a T of 4 squares.
Example
In the grid above, how big is the missing piece?
The target has 16 squares, and A, B and C cover 4 each, so the gap has 16−12=416 - 12 = 4 squares. That matches the four dots.

Idea 5: test in order: area, then length, then colour, then build

The four tests cost different amounts of time, so run the cheap ones first:
OrderTestTime
1Area adds up?seconds
2Lengths and rows fit?seconds
3Colours balance?a minute
4Build it, corners firstlonger
When you do need to build, start with the target's corners and its most awkward piece. A corner square can only be covered by a piece with a right-angled corner or a straight end there, so there are few choices, and a wrong choice shows up quickly.
Example
Which set might form a 3 by 4 rectangle: (i) four L-shaped pieces of 3 squares, (ii) three T-shaped pieces of 4 squares, (iii) pieces of 5, 4 and 4?
(iii) has area 13, not 12, so it fails Test 1. (ii) passes area but fails colour (Idea 3). Only (i) survives, and it builds easily (see Worked example 1).

How to spot which idea you need

The question says...Use
"which set of pieces forms..."Idea 5: run the tests in order
piece areas or sizes listedIdea 1: area
a long piece, or an odd-length sideIdea 2: lengths and rows
dominoes, squares removed from a boardIdea 3: chessboard colours
some pieces already placedIdea 4: the gap is the answer

Worked example 1warm-up

Show that four L-shaped pieces, each made of 3 unit squares, can form a 3 by 4 rectangle.
Solution
Step 1. AreaIdea 1
4×3=12=3×44 \times 3 = 12 = 3 \times 4.
Step 2. LengthsIdea 2
Each L is 2 squares long in each direction, which fits easily.
Step 3. Build from a cornerIdea 5: corners first
Put piece A in the top-left corner, covering (1,1)(1,1), (1,2)(1,2) and (2,2)(2,2). Put B in the top-right corner, covering (1,3)(1,3), (1,4)(1,4) and (2,4)(2,4). Put C in the bottom-left, covering (2,1)(2,1), (3,1)(3,1) and (3,2)(3,2). The last three squares (2,3)(2,3), (3,3)(3,3) and (3,4)(3,4) form an L, which is piece D.
c1c2c3c4
AABB
CADB
CCDD
Step 4. Check
Every square has exactly one letter, and each letter appears exactly 3 times in an L shape.

Worked example 2GATE level

A 6 by 6 board has two opposite corner squares removed. Can the remaining squares be covered exactly by 17 dominoes (1 by 2 pieces)?
Solution
Step 1. AreaIdea 1
36−2=34=17×236 - 2 = 34 = 17 \times 2, so area allows it.
Step 2. Colour the boardIdea 3
A 6 by 6 board has 18 black and 18 white squares.
Step 3. Find the colours of the removed squares
The corners are (1,1)(1, 1) and (6,6)(6, 6). Their row-plus-column sums are 2 and 12, both even, so both are black.
Step 4. Count what's left
18−2=1618 - 2 = 16 black and 18 white.
Step 5. Conclude
Each domino covers one black and one white square, so 17 dominoes would need 17 of each. The board has only 16 black squares, so no covering exists.
Step 6. Check
Removing two squares of different colours, such as (1,1)(1, 1) and (1,6)(1, 6) (sums 2 and 7), would leave 17 and 17, and then a covering is possible. The colour count, not the area, decides it.

All the rules at a glance

IdeaRule
Areapiece areas must add to the target area
Lengths and rowsno piece too long; odd rows need odd coverage
Coloura domino covers 1 black and 1 white
Missing piecetarget minus placed pieces
Orderarea, length, colour, then build from corners