HackTheRounds Interview Experiences
Goldman Sachs Technology Summer Analyst CoderPad Interview Experience (2026) - Grid Squares & Sliding Window, Pending
Goldman Sachs 2026 Technology Summer Analyst CoderPad OA plus math plus Hirevue walkthrough: count axis aligned squares, longest sliding window subarray, nine m
By Anonymous ยท 2026-03-18
Background
Going into my Goldman CoderPad round I had one rule: do not get clever. Everyone I talked to who had cleared a Goldman Summer Analyst Technology interview said the same thing, the problems are small, the math block is brutal, and they want to see you handle the boundary cases without flinching. I am a third-year CS undergrad with a back-end intern stint from last summer and a referral from a family friend on the Strats desk. This is a ground-level recap of the combined OA plus Hirevue stage, from the perspective of someone who over-prepared for algorithms and under-prepared for the math.
Timeline
- Referred application submitted: mid-February
- Recruiter phone intro: 10 days later
- CoderPad OA link: same week, 5-day window
- CoderPad session (coding plus math, back to back): day 2 of the window
- Hirevue behavioral invite: 5 days after CoderPad
- Hirevue submitted: 3 days after invite
- Super day status: awaiting invite
Total so far: 4 weeks.
CoderPad OA (2 coding, 9 math, ~95 minutes combined)
The CoderPad block is run as one continuous session. You log in, finish the coding half, the interface transitions you straight into the 9 math multiple choice questions, and the screen recorder stays on the whole time. There is no break. If you need water, grab it before you start.
Problem 1: Count axis-aligned squares inside a grid
Problem: Given a grid of row rows and col columns, and a list of queries of the form [r, c] , return for each query the total number of axis-aligned squares of any side length that fit inside an r by c sub-grid. Side lengths range from 1 up to min(r, c) .
For a square of side length a , the top-left corner can sit at any (i, j) with i + a <= r and j + a <= c , giving (r - a + 1) (c - a + 1) placements. Summing over a from 1 to min(r, c) is the full count. Per query this is O(min(r, c)), which is well inside the limits for reasonable r and c .
I spent the first two minutes drawing a 3x3 grid on the CoderPad scratchpad and literally counting. The formula jumps out once you see it. I almost reached for a 2D DP first, which would have been overkill.
The interviewer asked if I could get O(1) per query. You can, via the closed-form sum from a=1 to m of (r - a + 1)(c - a + 1) where m = min(r, c) , which expands to a cubic polynomial in m . I sketched the expansion verbally but stayed with the linear version for the submitted solution under time pressure.
Problem 2: Longest subarray with sum at most k
Problem: Given an array of non-negative integers and a target value k , return the length of the longest contiguous subarray whose sum is less than or equal to k .
Two-pointer sliding window. Because every element is non-negative, growing the right pointer never decreases the sum, and shrinking from the left never increases it. That monotonicity is what makes the window valid: whenever the running sum exceeds k , you shrink until it fits, and the best window length over the scan is the answer. O(n) time, O(1) space.
Before I wrote any code I said the invariant out loud: "all elements non-negative, so the prefix sum is monotone, so the window is monotone." The interviewer nodded. That single sentence separates candidates who are pattern matching from candidates who know why the technique applies.
The follow up was what changes if negatives are allowed. My answer: the sliding window breaks because the sum is no longer monotone, and you fall back to prefix sums plus a monotonic deque to find the minimum prefix in the last-k window. I walked through the idea verbally without coding it, which is what Goldman seems to reward on follow-ups.
Math Multiple Choice (9 questions, 40 minutes)
Goldman's math block is the filter almost nobody prepares for. It lands right after the coding with no break, and if you bomb it you do not advance no matter how clean your code was. Topics this cycle:
- Two dice-roll probability games, one with a tied-at-5 recovery probability, the other with a reroll-on-1 rule.
- A poker probability puzzle framed as "5 cards, 3 are aces, find the probability that 4 are aces." Stated literally, the event is impossible. Goldman wants you to flag the premise, not guess a fraction.
- A series with an integral definition, asked to find the general term.
- A derivative of a definite integral with variable bounds. Straight Leibniz rule.
- A 3x3 linear system, asked whether it is consistent and has a unique solution.
- A path integral over a parametric curve.
- Three true-or-false algebra statements involving eigenvalues, determinants, and the identity matrix.
- Sum of 100 iid Bernoulli variables with `p = 0.5`, probability the sum is under 60. CLT with continuity correction.
I brushed up on expected value, normal approximation, and eigenvalue intuition the weekend before. That review saved me on at least three questions.
Hirevue (6 questions, 45 second prep, 2 minute answer)
The Hirevue block ran the same cadence every Goldman candidate describes. Six questions, 45 seconds of prep between each, 2 minutes to answer. No re-records on the later questions.
- Walk through your resume.
- Working with someone who was not pulling their weight, what did you do.
- A challenging goal someone else said you could not hit.
- A time you turned down a project due to a conflict.
- You are in a no-teamwork individual project and a classmate offers help. What do you do.
- How do you debug.
Goldman is the third firm I have seen ask "how do you debug" as a behavioral question. It is not a trivia check. They want to hear hypothesis-driven thinking: form a theory, design a minimal repro, disprove fast, iterate. I framed it with a concrete bug story from my internship where I narrowed a flaky test down to a single race condition in about 200 lines of logs.
Result
Super day invite has not landed at the time of writing. Recruiter said decisions go out in two staggered batches within roughly two weeks of Hirevue submission.
Tips
- Draw, do not derive. For the squares problem, sketch a 3x3 grid and count. The formula `(r - a + 1)(c - a + 1)` is obvious from the picture and invisible from algebra.
- State the monotonicity aloud on Problem 2. Before writing the sliding window, say "all elements are non-negative, so the window is monotone." The interviewer is grading your reasoning, not just your code.
- Spend a weekend on the math surface area. Normal approximation with continuity correction, expected value, Leibniz rule, eigenvalue intuition, consistency of linear systems. That is the exact list Goldman tests. Skipping this block does not get you an offer.
- On the probability puzzle that looks impossible, flag the premise. The "4 aces from 5 cards when only 3 are aces" question rewards you for saying "this event has probability zero" rather than guessing a ratio.
- Prepare your resume walkthrough as a 90-second script and time it. If your Hirevue opener runs 2 minutes, your remaining answers will feel rushed. Cut filler words aggressively.
- For the debug question, use a real bug story, not a method overview. Goldman has heard "use print statements and check the stack trace" a thousand times. A concrete example of narrowing a race condition in 200 lines of logs is what gets remembered.