Data Structures & AlgorithmsModerateTCS NQT · Accenture
Problem: The product of the first 6 positive odd numbers 1·3·5·7·9·11 is computed. What is that product's value modulo 100?
- A. 45
- B. 35
- C. 80
- D. 95
Correct answer: D. 95
1 · 3 · 5 · 7 · 9 · 11 = 10395, so the result is 95. Stopping at 9 (945) gives 45, adding 13 gives 135135 → 35, and the first six even numbers give 46080 → 80.
More Coding Interview Problems questions
- Problem: A cyclic array [1, 2, 3, 4, 5] is rotated so that the element at index 0 becomes the element at index 2 (rotate left by 2). What…
- Problem: Starting from 5 on a number line, you may jump +2 or +3 each turn and must land exactly on 25. How many distinct jump sequences…
- Problem: A rectangle of 12 by 18 units is cut into the largest possible identical squares that tile it exactly. How many such squares are…
- Problem: The number 720 is written as a product of primes. What is the sum of its distinct prime factors?
- Problem: A grid of 2 rows and 5 columns is numbered row by row from 1. Each cell (r, c) holds (r·5 + c + 1). What is the value of the cell…
- Problem: Vertices 0–5 are connected by weighted undirected edges: 0-1 (2), 0-2 (4), 1-2 (1), 1-3 (7), 2-4 (3), 3-4 (2), 3-5 (1), 4-5 (5)…