Goldman Sachs interview questions

1,512 questions from 156 candidate reports · 2012 to 2025

Online test → Technical → Technical → Technical

DSA

Showing 29 of 893 reported in this area

Find the first non-repeating character in a string.
asked 13×easyPractice this →
Detect and remove a loop in a linked list.
asked 5×mediumPractice this →
Reduce a string by removing K consecutive identical characters
asked 4×mediumPractice this →
Find the longest palindromic substring in a given string
asked 3×mediumPractice this →
Minimum Number of Platforms Required for a Railway/Bus Station
asked 3×mediumPractice this →
Find the median of two sorted arrays.
asked 3×hardPractice this →
Implement a queue using two stacks.
asked 3×easyPractice this →
Maximum path sum in a matrix
asked 2×mediumPractice this →
Reverse a linked list in groups of size k.
asked 2×mediumPractice this →
Find the longest palindromic subsequence in a string
asked 2×mediumPractice this →
Check if a number can be written as a sum of K prime numbers
asked 2×mediumPractice this →
Find the smallest subarray with sum greater than a given value
asked 2×mediumPractice this →
Find the maximum of all subarrays of size K using a sliding window.
asked 2×mediumPractice this →
Find the maximum sum path in a matrix from bottom-left to top-right
asked 2×mediumPractice this →
Find the minimum length subarray with sum greater than a given value
asked 2×mediumPractice this →
Convert a Binary Search Tree to a sorted doubly linked list in place.
asked 2×mediumPractice this →
Given an array of numbers, arrange them to form the largest possible number
asked 2×mediumPractice this →
Minimum number of platforms required for a railway/bus station given arrival and departure times
asked 2×mediumPractice this →
Given an array of N integers in the range [a, b] with five numbers missing, find the five missing numbers.
asked 2×mediumPractice this →
Egg Dropping Puzzle
asked 2×hardPractice this →
Trapping Rain Water
asked 2×hardPractice this →
Find the median of a stream of running integers
asked 2×hardPractice this →
Detect a loop in a doubly linked list
asked 2×easyPractice this →
Find the middle of a linked list in one pass.
asked 2×easyPractice this →
Find the intersection point of two linked lists
asked 2×easyPractice this →
Implement Run Length Encoding for a given string
asked 2×easyPractice this →
Search an element in a row-wise and column-wise sorted matrix.
asked 2×easyPractice this →
Rotate a given matrix by 90 degrees in anti-clockwise direction
asked 2×easyPractice this →
Set Matrix Zeroes.
asked oncemediumPractice this →

CS fundamentals

Showing 17 of 530 reported in this area

Explain the Singleton design pattern
asked 4×easyPractice this →
Explain the HashMap contract in Java.
asked 2×mediumPractice this →
Explain the internal working of HashMap.
asked 2×mediumPractice this →
How does HashMap work internally in Java?
asked 2×mediumPractice this →
Explain the internal working of HashMap in Java.
asked 2×mediumPractice this →
What is multithreading and how is it implemented in Java?
asked 2×mediumPractice this →
Explain Java 8 features
asked 2×easyPractice this →
Explain OOP concepts in Java.
asked 2×easyPractice this →
Explain the final keyword in Java.
asked 2×easyPractice this →
What are the differences between C++ and Python?
asked 2×easyPractice this →
Explain polymorphism in Object-Oriented Programming
asked 2×easyPractice this →
Explain the difference between a process and a thread
asked 2×easyPractice this →
Explain the difference between == and equals() in Java.
asked 2×easyPractice this →
Explain method overloading and method overriding in Java.
asked 2×easyPractice this →
Explain the contract between hashCode() and equals() in Java.
asked 2×easyPractice this →
What is the difference between pointers and reference variables in C++?
asked 2×easyPractice this →
Explain the difference between an interface and an abstract class in Java.
asked 2×easyPractice this →

Puzzles

Showing 5 of 140 reported in this area

100 Doors puzzle
asked oncemediumPractice this →
Gold bar puzzle.
asked oncemediumPractice this →
8 marbles puzzle.
asked oncemediumPractice this →
Two pills puzzle.
asked oncemediumPractice this →
Bag of coins puzzle.
asked oncemediumPractice this →

Aptitude

Showing 3 of 107 reported in this area

Reading comprehension questions based on passages
asked 3×easyPractice this →
Find the tens digit of 2^130.
asked oncemediumPractice this →
Probability-based puzzle problem
asked oncemediumPractice this →

System design

Showing 3 of 88 reported in this area

Design and implement an LRU Cache
asked 3×mediumPractice this →
Design a Library Management System
asked 2×mediumPractice this →
Design a rate limiter API
asked oncemediumPractice this →

Behavioural

Showing 3 of 48 reported in this area

Has technology taken over us or have we taken over technology?
asked oncemediumPractice this →
For a project or assignment, describe a time you faced a major obstacle and what was the most exciting part of working on it.
asked oncemediumPractice this →
In a two-person team project, how would you handle the situation if the other member faces a personal problem and cannot continue?
asked oncemediumPractice this →

Showing 60 of 1,512 questions. Ranked by how often the same question came back across reports.

Practise a Goldman Sachs-style interview

A spoken interview built from these questions, scored when you finish; the report is yours.

Start practising

Common questions

What questions does Goldman Sachs ask?

Candidate interview reports most often cover DSA (49%) and CS fundamentals (29%).

How many rounds does Goldman Sachs interview have?

Candidate interview reports show an average of 4.3 rounds per experience, with a typical sequence of Online test → Technical → Technical → Technical. Individual interview paths can vary.

Is the Goldman Sachs interview hard?

Among questions with a reported difficulty, the mix is easy 31%, medium 58%, hard 11%.

Keep reading