Technical MCQs
Revision notes and 30 original questions on tracing, networks, cloud, security, OS/OOP, SQL, and MS Office.
Research checked: 13 November 2026. Technical MCQs are confirmed for your drive. Topic choices are informed by recent campus reports, which are not an official internship syllabus. All 30 questions below are original practice.
Fast revision sheet
| Area | What to remember |
|---|---|
| Tracing | Write the value after each assignment. AND &, OR |, and XOR ^ operate on bits; XOR gives 1 for differing bits. Do not confuse logical AND with bitwise AND. |
| Loops | Track initialization, condition, body, then update. Watch inclusive endpoints, integer division, and a variable changed inside the loop. |
| Networks | DNS resolves names; TCP supplies a reliable ordered byte stream; IP routes packets; TLS protects transport. HTTP status codes describe application responses. |
| Cloud/security | IaaS exposes compute infrastructure; PaaS manages more of the application platform; SaaS supplies an application. Know least privilege, MFA, shared responsibility, and scaling. |
| OS/OOP | Threads share process resources; race conditions involve unsynchronized shared state. Encapsulation protects invariants; overriding changes inherited instance-method behavior. |
| SQL | Follow join keys, preserve unmatched rows deliberately, count non-NULL keys, and distinguish row filters from group filters. |
| Office | Excel relative vs absolute references, SUMIF, Word heading styles, and PowerPoint master layouts. |
Practice protocol: attempt Q1–Q10 on 13 November, Q11–Q30 on 14 November, then reattempt all 30 with answers closed on 15 November. Budget about one minute per question as a study timer, not your test's stated timing. Explanations are inside each collapsed answer. For all pseudocode below, integers use Java-like semantics, ranges are specified, and print prints the final value.
Pseudocode and Java fundamentals
Q1 — Bitwise XOR
What is 6 ^ 3? A. 2 · B. 5 · C. 7 · D. 9
Answer Q1
B — 5. In binary, 110 XOR 011 = 101. A is bitwise AND, C is OR, and D incorrectly treats the operation as addition.
Q2 — Sequential assignment
Start a = 5, b = 2; execute a = a + b, then b = a - b. What is b? A. 2 · B. 3 · C. 5 · D. 7
Answer Q2
C — 5. The second assignment sees the updated a = 7, so b = 7 - 2. A keeps the old value; B uses the original a; D is the new a, not b.
Q3 — Loop boundaries
Start sum = 0; for i = 1 through 4 inclusive, add i only when even. Final sum? A. 2 · B. 4 · C. 6 · D. 10
Answer Q3
C — 6. Add 2 and 4. A misses the inclusive endpoint; B omits the earlier even value; D includes odd values.
Q4 — Integer division
What is 7 / 2 + 7 % 2 using integer operands? A. 3 · B. 3.5 · C. 4 · D. 4.5
Answer Q4
C — 4. Integer division gives 3 and the remainder is 1. B and D assume fractional division; A omits the remainder.
Q5 — Short-circuit condition
In Java, x = 0; evaluate x != 0 && 10 / x > 1. What happens? A. True · B. False, no exception · C. Division-by-zero exception · D. Compilation fails
Answer Q5
B. The left operand is false, so && does not evaluate the right operand. Using boolean & instead would evaluate both. The expression is valid Java, and the first condition cannot be true here.
Q6 — While-loop trace
Start n = 19, count = 0. While n > 0, set n = n / 2 using integer division, then increment count. Final count? A. 4 · B. 5 · C. 9 · D. 19
Answer Q6
B — 5. Values after division are 9, 4, 2, 1, 0; each iteration increments count, including the one producing zero. A misses that last iteration; C and D confuse values with iteration count.
Q7 — AND then OR
Evaluate (12 & 10) | 1. A. 1 · B. 8 · C. 9 · D. 15
Answer Q7
C — 9. 1100 AND 1010 = 1000; OR with 0001 gives 1001. B forgets the final OR, A forgets the intermediate result, and D sets bits not present in that result.
Q8 — Small recursion
Define f(0)=0; for positive n, f(n)=n+f(n-1). What is f(3)? A. 3 · B. 5 · C. 6 · D. Infinite recursion
Answer Q8
C — 6. Expand 3 + 2 + 1 + 0. The base case is reached, so D is wrong; A and B omit terms.
Q9 — Content equality
In Java, String a = new String("oa"); String b = new String("oa");. Which expression is true? A. a == b · B. a.equals(b) · C. Both · D. Neither
Answer Q9
B. new creates distinct objects, so reference equality is false; .equals compares String contents. This example deliberately avoids interning of two literal references.
Q10 — Pair counting
For an array of length n, a loop runs j from i + 1 to n - 1 for every i from 0 to n - 1. How many pairs? A. n · B. n² · C. n(n-1)/2 · D. 2n
Answer Q10
C. The inner counts are n-1, n-2, …, 0. Each unordered pair of distinct indices occurs once, giving quadratic time but not exactly n² executions.
- Attempt Q1–Q10 and retrace every incorrect answer.
Networking, cloud, and security
Q11 — DNS
A hostname needs to be mapped to an IP address. Which service is primarily responsible? A. DNS · B. DHCP · C. TLS · D. SMTP
Answer Q11
A. DNS resolves names. DHCP assigns network configuration, TLS protects communications, and SMTP transports email. A cached answer may avoid a new DNS query, but it does not change the service's purpose.
Q12 — TCP
Which property does TCP provide to applications? A. Guaranteed fixed latency · B. Reliable ordered byte stream · C. Built-in encryption · D. Guaranteed message boundaries
Answer Q12
B. TCP orders and retransmits bytes. It does not promise fixed latency, preserve each application's write as a separate message, or encrypt by itself; applications add framing and often TLS.
Q13 — HTTPS
Which statement is accurate? A. HTTPS prevents all SQL injection · B. HTTPS proves content is truthful · C. TLS protects data in transit and authenticates the server through certificate validation · D. HTTPS makes authorization unnecessary
Answer Q13
C. Transport protection does not validate application inputs, establish the truth of content, or decide what a logged-in user may access. Those require separate application controls.
Q14 — Suspicious email
An unexpected email asks for your password using an urgent link. Best first action? A. Reply with the password · B. Open the link to inspect its form · C. Verify through the known official channel and report it · D. Forward it to everyone
Answer Q14
C. Use a trusted independently known channel. Sending credentials exposes them, clicking can expose you to phishing, and forwarding broadly spreads the malicious message.
Q15 — Least privilege
A service only needs to read one storage bucket. Which permission fits? A. Organization admin · B. Read access to that bucket only · C. Write access to all buckets · D. Shared root credentials
Answer Q15
B. Grant only the required action on the required resource. The other options add unrelated authority or share powerful credentials, increasing the damage if the service is compromised.
Q16 — Service model
You rent a virtual machine and manage its operating system and application. Which model is this? A. SaaS · B. PaaS · C. IaaS · D. DNS
Answer Q16
C. IaaS exposes infrastructure such as virtual machines. PaaS manages more of the runtime/platform; SaaS delivers an application. DNS is a network service, not this cloud service-model classification.
Q17 — Scaling
Adding two more application instances behind a load balancer is what? A. Horizontal scaling · B. Vertical scaling · C. Encryption · D. Normalization
Answer Q17
A. Horizontal scaling adds instances. Vertical scaling increases one instance's capacity. Encryption and database normalization address different concerns. Shared state and sessions may need attention when adding instances.
Q18 — Shared responsibility
On an IaaS VM, who generally patches the guest operating system? A. The DNS provider · B. Nobody · C. The customer · D. Always the cloud provider
Answer Q18
C. With a standard IaaS VM, the customer manages the guest OS while the provider manages underlying infrastructure. Managed service contracts can move responsibilities; do not assume IaaS has the same division as SaaS.
- Attempt Q11–Q18 and explain the terms without memorizing letters.
OS, OOP, and SQL
Q19 — Threads
Two threads in the same process generally share which resource? A. The same call stack · B. Process heap/address space · C. The same instruction pointer · D. No memory
Answer Q19
B. Threads share process memory/resources but have their own stacks and execution state. Sharing memory enables communication and creates synchronization needs.
Q20 — Deadlock
Thread A holds lock X and waits for Y; thread B holds Y and waits for X, with no release or timeout. What is the risk? A. Deadlock · B. Compilation error · C. Automatic successful retry · D. Guaranteed starvation-free execution
Answer Q20
A. Each waits for a resource held by the other. A consistent global lock order can prevent this cycle; the runtime does not necessarily resolve it automatically.
Q21 — Overriding
A subclass supplies a compatible implementation of an inherited instance method with the same signature. This is what? A. Overloading · B. Encapsulation · C. Overriding · D. Serialization
Answer Q21
C. Overriding changes inherited instance behavior and supports dynamic dispatch. Overloading uses different parameter signatures; encapsulation controls access to state; serialization represents data for storage/transport.
Q22 — Encapsulation
Which best protects a non-negative balance invariant? A. Public writable balance field · B. Private balance with validated update methods · C. Naming the field BALANCE · D. A comment asking callers to be careful
Answer Q22
B. Restrict direct writes and validate state changes. Naming conventions and comments do not enforce an invariant; a public field lets callers bypass the rule.
Q23 — NULL and COUNT
A column contains 10, NULL, 20. What do COUNT(*) and COUNT(column) return? A. 2 and 2 · B. 3 and 3 · C. 3 and 2 · D. 2 and 3
Answer Q23
C. COUNT(*) counts all three rows; COUNT(column) ignores the NULL. Neither operation sums the numeric values.
Q24 — Preserving a LEFT JOIN
You must retain customers without paid orders. Where should o.status = 'paid' go when LEFT JOINing orders? A. ON with the customer key · B. WHERE only · C. ORDER BY · D. GROUP BY only
Answer Q24
A. Filtering matches in ON preserves the unmatched customer row. A WHERE o.status = 'paid' condition removes its NULL-extended row. Sorting and grouping do not select paid matches.
Q25 — Group filter
Which clause keeps only customers whose total paid amount exceeds 100 after aggregation? A. WHERE SUM(amount) > 100 · B. HAVING SUM(amount) > 100 · C. ORDER BY amount > 100 · D. JOIN SUM(amount) > 100
Answer Q25
B. Aggregate group conditions belong in HAVING. WHERE filters source rows before aggregation, ORDER BY sorts, and D is not a valid join expression for this purpose.
Q26 — Primary keys
Which constraint does a primary key enforce? A. Repeated NULL values only · B. Unique, non-NULL identification of rows · C. Alphabetical order · D. Automatic encryption
Answer Q26
B. A primary key identifies each row uniquely and cannot be NULL under standard relational SQL semantics. Physical ordering and encryption are separate concerns. Some legacy SQLite table modes have NULL quirks; do not generalize those to other systems.
- Attempt Q19–Q26 and revisit any missed SQL query on the practice database.
MS Office fundamentals
Q27 — Absolute Excel reference
Cell C2 contains =A2*$B$1. Copy it to C3. What is the formula? A. =A3*$B$1 · B. =A3*$B$2 · C. =A2*$B$1 · D. =B3*$C$1
Answer Q27
A. A2 is relative and moves down one row; $B$1 fixes both column and row. The other answers move a fixed reference or fail to move the relative one.
Q28 — Conditional Excel sum
Column A holds categories and column B holds amounts, rows 2–10. Which sums amounts for category Books? A. =COUNTIF(A2:A10,"Books") · B. =SUM(B2:B10) · C. =SUMIF(A2:A10,"Books",B2:B10) · D. =AVERAGE(B2:B10)
Answer Q28
C. SUMIF uses a criteria range, criterion, and sum range. A counts matches, B ignores the category, and D computes an unconditional mean. Formula argument separators may vary by locale.
Q29 — Word headings
You want a consistently structured document and an automatically generated table of contents. What helps most? A. Bold every title manually · B. Use heading styles with appropriate levels · C. Add blank lines · D. Insert a screenshot of the title list
Answer Q29
B. Heading styles carry document structure used by navigation and a generated contents table. Manual appearance and screenshots do not establish that structure.
Q30 — PowerPoint consistency
You need a logo and common formatting across many slide layouts. Which feature is designed for that? A. Slide Master/layouts · B. Spellcheck · C. Notes pane · D. Rehearse Timings
Answer Q30
A. The master and layouts centralize shared slide design. Spellcheck, speaker notes, and rehearsal timing serve other purposes. Individual slide overrides can still affect the visible result.
- Attempt Q27–Q30 and distinguish a feature's purpose from its menu location.
Targeted resources and final review
- Dev.java: Language Basics and OOP for operators, loops, strings, and overriding.
- Microsoft cloud concepts: cloud models, scaling, and shared responsibility. Read the concepts; no subscription purchase is needed for revision.
- MDN overview of HTTP: client/server flow, statelessness, and the roles of HTTP and TCP/TLS.
- Excel help, Word help, and PowerPoint help: look up relative/absolute references, SUMIF, heading styles, and Slide Master specifically.
Record your practice score and the concept missed, then reattempt. No practice score on this page is an Accenture cutoff. Return to the dated study plan.