Goldman Sachs interview experience Real time questions & tips from candidates to crack your interview

Software Analyst

Goldman Sachs
upvote
share-icon
3 rounds | 8 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 12 months
Topics: Data Structures, Graphs, DP, OOPS, DBMS, Algorithms
Tip
Tip

Tip 1 : Practice daily
Tip 2 : Have 2 good projects in resume
Tip 3 : I refer popular DSA question sheets from internet

Application process
Where: Campus
Eligibility: 7 CGPA
Resume Tip
Resume tip

Tip 1 : Include 2-3 projects
Tip 2 : Have separate resumes for all the roles you are applying
Tip 3 : Walk through your resume multiple times

Interview rounds

01
Round
Medium
Online Coding Test
Duration110 minutes
Interview date15 Aug 2021
Coding problem3

1. Best Time to Buy and Sell Stock

Moderate
20m average time
80% success
0/80
Asked in companies
IntuitOptumOYO

You are given an array/list 'prices' where the elements of the array represent the prices of the stock as they were yesterday and indices of the array represent minutes. Your task is to find and return the maximum profit you can make by buying and selling the stock. You can buy and sell the stock only once.

Note:

You can’t sell without buying first.
For Example:
For the given array [ 2, 100, 150, 120],
The maximum profit can be achieved by buying the stock at minute 0 when its price is Rs. 2 and selling it at minute 2 when its price is Rs. 150.
So, the output will be 148.
Try solving now

2. Longest Substring with At Most K Distinct Characters

Moderate
20m average time
80% success
0/80
Asked in companies
AmazonMedia.netGoldman Sachs

You are given a string 'str' and an integer ‘K’. Your task is to find the length of the largest substring with at most ‘K’ distinct characters.

For example:
You are given ‘str’ = ‘abbbbbbc’ and ‘K’ = 2, then the substrings that can be formed are [‘abbbbbb’, ‘bbbbbbc’]. Hence the answer is 7.
Problem approach

Do practice for DP questions

Try solving now

3. Rotting Oranges

Moderate
20m average time
78% success
0/80
Asked in companies
Samsung R&D InstituteSalesforceSamsung

You have been given a grid containing some oranges. Each cell of this grid has one of the three integers values:

  • Value 0 - representing an empty cell.
  • Value 1 - representing a fresh orange.
  • Value 2 - representing a rotten orange.
  • Every second, any fresh orange that is adjacent(4-directionally) to a rotten orange becomes rotten.

    Your task is to find out the minimum time after which no cell has a fresh orange. If it's impossible to rot all the fresh oranges then print -1.

    Note:
    1. The grid has 0-based indexing.
    2. A rotten orange can affect the adjacent oranges 4 directionally i.e. Up, Down, Left, Right.
    
    Try solving now
    02
    Round
    Easy
    Video Call
    Duration30 minutes
    Interview date16 Aug 2021
    Coding problem2

    Interviewer first came and introduced himself and asked me to introduce
    Then he asked me a coding questions followed by one probability question.

    1. One Away

    Moderate
    15m average time
    90% success
    0/80
    Asked in companies
    PayPalGoldman SachsMicrosoft

    You are given two strings, string A and string B. Your task is to determine whether string A can be transformed into string B by performing only one of the following operations at most one (or maybe zero) time.

    1. You can delete a character from any position.
    2. You can replace a character with any other character.
    3. You can insert a character at any position. 
    

    Note :

    1. The strings are non-empty.
    2. The strings only contain lowercase English letters.
    
    Try solving now

    2. Probability Question

    When we roll two fair dice, What is the expected number that outcome on both dices are 6?

    03
    Round
    Hard
    Video Call
    Duration100 minutes
    Interview date16 Aug 2021
    Coding problem3

    Interviewer first came and asked me my interests and what I wanna pursue in future.
    Then he asked me if I am familiar with probability or not, I said I may try but I am better in DSA and coding questions.
    Then he said he want to test my problem solving skills and how I tackle new questions.

    1. Group Anagrams

    Moderate
    30m average time
    70% success
    0/80
    Asked in companies
    AmazonAtlassianThales

    You have been given an array/list of strings 'inputStr'. You are supposed to return the strings as groups of anagrams such that strings belonging to a particular group are anagrams of one another.

    An anagram is a word or phrase formed by rearranging the letters of a different word or phrase. We can generalize this in string processing by saying that an anagram of a string is another string with the same quantity of each character in it, in any order.

    Note:
    The order in which the groups and members of the groups are printed does not matter.
    
    For example:
    inputStr = {"eat","tea","tan","ate","nat","bat"}
    Here {“tea”, “ate”,” eat”} and {“nat”, “tan”} are grouped as anagrams. Since there is no such string in “inputStr” which can be an anagram of “bat”, thus, “bat” will be the only member in its group.
    
    Try solving now

    2. Missing and repeating numbers

    Moderate
    25m average time
    75% success
    0/80
    Asked in companies
    Goldman SachsGrowwShareChat

    You are given an array of size ‘N’. The elements of the array are in the range from 1 to ‘N’.

    Ideally, the array should contain elements from 1 to ‘N’. But due to some miscalculations, there is a number R in the range [1, N] which appears in the array twice and another number M in the range [1, N] which is missing from the array.

    Your task is to find the missing number (M) and the repeating number (R).

    For example:
    Consider an array of size six. The elements of the array are { 6, 4, 3, 5, 5, 1 }. 
    The array should contain elements from one to six. Here, 2 is not present and 5 is occurring twice. Thus, 2 is the missing number (M) and 5 is the repeating number (R). 
    
    Follow Up
    Can you do this in linear time and constant additional space? 
    
    Try solving now

    3. Project Question

    Why do you choose these tech stacks for your project?

    What is the main functionality of your project?

    Here's your problem of the day

    Solving this problem will increase your chance to get selected in this company

    Skill covered: Programming

    How do you remove whitespace from the start of a string?

    Choose another skill to practice
    Similar interview experiences
    company logo
    Software Analyst
    4 rounds | 8 problems
    Interviewed by Goldman Sachs
    8978 views
    1 comments
    0 upvotes
    company logo
    Software Analyst
    4 rounds | 6 problems
    Interviewed by Goldman Sachs
    2826 views
    0 comments
    0 upvotes
    company logo
    Software Analyst
    4 rounds | 10 problems
    Interviewed by Goldman Sachs
    5003 views
    0 comments
    0 upvotes
    company logo
    Software Analyst
    3 rounds | 9 problems
    Interviewed by Goldman Sachs
    1027 views
    0 comments
    0 upvotes