Citadel Software Engineer Coding & Algorithms Interview Questions
Master your tech interview with our curated database of real questions from top companies.
Find earliest common meeting slot
Given K participants' calendars, each a list of busy intervals [start, end) within a working window [workStart, workEnd], and a meeting duration d min...
Solve four algorithmic problems
Answer the following independent algorithmic questions: 1) Count extendable prefixes for '10' subsequences: Given a binary string s and an integer k, ...
Minimize image processing cost with discount
Question You have n images. For the i-th image, processing costs filterCost[i] per day and must run from startDay[i] to endDay[i] inclusive. Each day ...
Minimize changes for k-periodic palindrome
Question Given a string currentPassword (length N) and an integer k (1 ≤ k < N, N ≤ 2·10^5, lowercase letters, N divisible by k), find the minimum num...
Optimize password transform and discount scheduling
Part 1 — Transform to palindromic k-periodic string: Input: a lowercase string currentPassword and integer k. Constraints: 1 <= k < len(currentPasswor...
Explain hash maps and solve array intersection
1) Explain the internal implementation of a hash map: underlying array/bucket layout, hash function choice, collision resolution strategies (separate ...
Solve two DS&A optimization problems
Problem 1 — Maximize alternating-sum over four array partitions: Given an integer array arr[1..n] (1-based). Choose indices a, b, c with 1 ≤ a ≤ b ≤ c...