Background: undergrad. DRW 2027 Summer Quant Developer Intern (Python), Singapore. Applied online, August 2026. Everything was online (virtual), four rounds in total. Result: rejected.
[Round 1]
Resume deep dive: my two previous internships, with follow-ups on embeddings and on why I chose BERT.
Hand-write merge sort. I'd suggest reviewing all the sorting algorithms.
Python decorator: first add 1 to every element of the array and then run merge sort; the follow-up changed it to +x.
My approach: the follow-up needs a decorator that takes an argument (three nested levels: the decorator factory takes x, then the decorator, then the wrapper). Remember to use functools.wraps.
Implement a rate limiter (if the limit is exceeded, wait and then send): store timestamps in a deque, pop the timestamps that fall outside the window, and send once len(deque) < limit. With multiple clients, use a lock so only one thread modifies the deque at a time.
Extra note: don't hold the lock while sleeping. Work out the wait time, release the lock, then go wait.
[Round 2: Rolling VWAP]
Given trade objects (symbol, price, qty, timestamp), compute the rolling VWAP of a given ticker over a fixed sliding window.
My approach: one deque per symbol, keep a running sum of price x qty and a running sum of qty inside the window, and add a cleanup function that pops expired trades. VWAP = sum(price x qty) / sum(qty), amortized O(1).
Follow-up: the window length can vary.
My approach: for each symbol, store an array sorted by time along with prefix sums of price x qty and of qty. At query time, binary search for the start of the window, O(log n).
Follow-up: multiple threads reading the VWAP.
My approach: find the critical sections (writing a trade and reading the prefix sums) and add locks. You can use one lock per symbol to cut down contention.
[Round 3]
Find the k-th largest subarray sum.
My approach: if n is small, use prefix sums to enumerate all the subarray sums and keep a min-heap of size k, O(n^2 log k). If all the numbers are non-negative, you can binary search on the answer and use two pointers to count the subarrays with sum >= mid, O(n log S).
[Round 4: Basket pricing]
M products and N baskets. Example: Products = {GOOG: 10, AAPL: 20, SPCX: 30, QQQM: 40}, Baskets = [[GOOG, AAPL], [AAPL, SPCX, QQQM], [QQQM, GOOG]].
Implement init, update(prod_id, new_price), and query(X), which returns the number of baskets whose total price is <= X.
My approach: build a reverse index from product to baskets and keep a total price for each basket. On update, only add the price difference to the baskets that contain that product. Put all the basket totals in a SortedList and use bisect for query, O(log N). Update is O(number of baskets containing the product x log N).
[Summary]
It leans toward engineering implementation plus concurrency. You need to know the Python details well (decorators, threading.Lock), and there are a lot of follow-ups.
Discussion
Loading comments…