Bộ bài tập tự sinh (10 câu · Suy luận logic, Thứ tự & Tập hợp)
Mã đề: 40246941 · Khớp 29 mẫu bài trong thư viện.
Question 1
Trung bình · +2 điểm
One-way roads connect towns with travel times: $A\to B$ ($5$ min), $B\to C$ ($6$ min), $A\to C$ ($15$ min), $B\to D$ ($11$ min), and $C\to D$ ($5$ min). What is the shortest time (in minutes) to go from $A$ to $D$?
Xem đáp án và lời giải
Đáp án: $16$
So sánh $3$ lộ trình từ $A$ đến $D$:
- $A\to B\to C\to D$: $16$
- $A\to B\to D$: $16$
- $A\to C\to D$: $20$
Đường ngắn nhất mất $16$ phút.
A pile has $27$ coins. Two players take turns removing $1$ to $3$ coins, and the player forced to take the last coin LOSES. How many coins should the first player take on move $1$ to leave a winning remainder ($\equiv 1 \pmod{4}$)?
Xem đáp án và lời giải
Đáp án: $2$
Muốn đối thủ bốc viên cuối, cần đưa tổng về dạng $(4)m + 1$. Ta có $27 - 2 = 25 \equiv 1 \pmod{4}$, nên bốc $2$ đồng xu.
In a $4 \times 4$ mini-Sudoku (using digits $1, 2, 3, 4$ once per row, column, and $2 \times 2$ box), row $1$ already has $1, 4$ and column $4$ already has $2$ outside row $1$. What digit MUST go in row $1$, column $4$?
Xem đáp án và lời giải
Đáp án: $3$
Hàng $1$ đã có $1, 4$ và cột $4$ đã có $2$, nên ô giao nhau chỉ có thể là chữ số còn lại là $3$.
Question 4
Trung bình · +2 điểm
Given binary inputs $A = 1, B = 0, C = 1, D = 1$, evaluate the four logic gates:
- $G_1 = A \text{ AND } B$
- $G_2 = C \text{ OR } D$
- $G_3 = A \text{ XOR } C$
- $G_4 = B \text{ XOR } D$
How many of these four gates output $1$?
Xem đáp án và lời giải
Đáp án: $2$
Tính từng cổng: $G_1 = 0, G_2 = 1, G_3 = 0, G_4 = 1$. Tổng số cổng có đầu ra $1$ là $2$.
An apple weighs $169\text{ g}$. A pear is $59\text{ g}$ heavier than the apple, and a mango is $35\text{ g}$ lighter than the pear. How much does the mango weigh (in grams)?
Xem đáp án và lời giải
Đáp án: $193$
Quả lê nặng $169 + 59 = 228\text{ g}$, nên quả xoài nặng $228 - 35 = 193\text{ g}$.
Question 6
Trung bình · +2 điểm
Letters $A$–$Z$ are numbered $1$–$26$ ($A=1, \dots, Z=26$). A Caesar cipher shifts every letter forward by $10$ positions, wrapping around after $26$ back to $1$. What position number does letter #19 shift to?
Xem đáp án và lời giải
Đáp án: $3$
Ta có $19 + 10 = 29$. Vì vượt quá $26$, quay vòng trừ đi $26$ được $3$.
Question 7
Trung bình · +2 điểm
$1$ melon weighs as much as $2$ apples, and $1$ apple weighs as much as $4$ strawberries. If $1$ strawberry weighs $5\text{ g}$, how many grams does $1$ melon weigh?
Xem đáp án và lời giải
Đáp án: $40$
$1$ quả dưa nặng bằng $2 \times 4 = 8$ quả dâu, tức là $8 \times 5 = 40\text{ g}$.
In a game of Nim, there are three piles with $3$, $10$, and $11$ stones. On your turn, you may remove any positive number of stones from a single pile (the player taking the last stone wins). How many stones must you remove from the pile of $11$ to reach a winning Nim-sum ($0$) position?
Xem đáp án và lời giải
Đáp án: $2$
Tính tổng XOR hai đống đầu: $3 \oplus 10 = 9$. Cần giảm đống $11$ xuống còn $9$, tức là bốc đi $11 - 9 = 2$ viên.
The integers $1, 2, 3, \dots, 16$ are written on a board. In each step, you erase any two numbers $a$ and $b$ and write $a + b - 1$. After $15$ steps, only $1$ number remains. What is that final number?
Xem đáp án và lời giải
Đáp án: $121$
Mỗi bước tổng các số giảm đi $1$. Sau $15$ bước, số cuối cùng bằng $(1 + 2 + \cdots + 16) - (16 - 1) = 136 - 15 = 121$.
Question 10
Trung bình · +2 điểm
A box contains $10$ balls of each of $4$ different colors. What is the minimum number of balls you must pull out without looking to guarantee having at least $3$ balls of the same color?
Xem đáp án và lời giải
Đáp án: $9$
Trường hợp xấu nhất rút mỗi màu $2$ viên: $4 \times 2 = 8$ viên. Viên thứ $9$ chắc chắn tạo đủ $3$ viên cùng màu.