What's the 2's complement of 10011101?
01100011
What is the difference between a primary key and a foreign key?
A primary key uniquely identifies each row in a table. A foreign key is a field in one table that references the primary key of another table.
What is the answer to Math.floor(4.8) ?
4. (Rounds down to the nearest integer)
What is the difference between a vector and a scalar? Give one example of each.
A vector has magnitude and direction (e.g. velocity). A scalar has magnitude only (e.g. speed).
Name the first 5 digits of Pi
An automatic irrigation system activates (output W = 1) when:
- It is daytime (D = 1) AND the soil is dry (S = 1)
- OR when manual override (M = 1) is activated
Write the Boolean expression for W.
W = (D AND S) OR M
or algebraically: W = DS + M
Name the four text pre-processing steps used in web search engines.
Case folding, punctuation removal, stop word removal, and stemming.
What does the following do?
int j = 0;
do {
j++;
printf(j);
} while ( j < 4);
Prints 1,2,3,4
(Even CEIM Leaders got confused)
Name the three methods of heat transfer.
Conduction, convection, and radiation.
What is currently the highest-rated film on IMDb?
The Shawshank Redemption
A custom encoding system uses 10 bits per character. How many unique characters can this system represent?
2^10 = 1,024 unique characters
What is the Big-O time complexity of binary search vs linear search in the worst case?
Linear search is O(N). Binary search is O(log N).
List the style types in order of highest to lowest priority. (Embedded, External, Inline)
Inline -> Embedded -> External
A capacitor stores 4.3 μC at 1.5 V. What's the capacitance?
C = q/V = 4.3 × 10⁻⁶ / 1.5 = 2.87 μF
How many ghosts chase Pac-Man at the start of each game?
4
Consider the following network graph where all edges have equal weight (1 hop):
- Nodes: P, Q, R, S, T, U
- Edges: P-Q, P-R, Q-S, R-S, R-T, S-U, T-U
Identify ALL shortest paths from node P to node U and how many hops are needed per path.
Path 1: P → Q → S → U (3 hops)
Path 2: P → R → S → U (3 hops)
Path 3: P → R → T → U (3 hops)
In the context of recommender systems, what is the difference between a personalised and a non-personalised approach?
Personalised uses individual user preferences and similarity scores (e.g. Pearson correlation) to tailor recommendations. Non-personalised recommends the same thing to everyone (e.g. highest average rating).
What is a pointer?
A pointer is a variable whose value is the address of another variable
How many protons and neutrons are in ⁸⁸Ra²²⁶?
Protons = atomic number = 88. Neutrons = mass number − atomic number = 226 − 88 = 138 neutrons.
Which metal is most commonly used for electrical wiring?
Copper
Given the commands in base-5 with digits: W = 0, X = 1, Y = 2, Z = 3. Convert the coordinate "X Z Y W X" to its decimal equivalent.
X Z Y W X = 1 3 2 0 1 (in base-5)
=(1*5^4)+(3*5^3)+(2*5^2)+(0*5^1)+(1*5^0)=(1*625)+(3*125)+(2*25)+(0*5)+(1*1)=625+375+50+0+1=1051
What is the edge density formula for a directed network, and what does it measure?
Edge density = number of edges / number of possible edges. For a directed graph: D = E / (N × (N − 1)). It measures how connected the network is as a fraction of the maximum possible connections.
What is "r+" in file mode?
E.g. fopen_s(&fptr, filename, "r+");
Opens a file for BOTH reading and writing
A ball is thrown straight up and rises 1.25 m. What was its initial velocity?
v² = v₀² + 2ax → 0 = v₀² − 2(9.81)(1.25) → v₀ = √24.525 ≈ 4.95 m/s
What does QR (in QR code) stand for?
Quick Response