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

SDE - 1

Salesforce
upvote
share-icon
3 rounds | 9 Coding problems

Interview preparation journey

expand-icon
Journey
My journey toward landing a Salesforce job began during my first year of college when I started coding from scratch. I invested countless hours learning the basics through platforms, focusing on C++. Eager to apply my skills, I participated in numerous coding contests on coding platforms and joined as many hackathons as possible, gaining invaluable teamwork and innovation experience. All of this culminated in securing my internship at Salesforce.
Application story
I saw the opportunity in the college email and applied for it the same day. I received the online assessment date a few days later and started preparing for it. I passed the online assessment and moved on to the interview rounds. After three interview rounds, I was finally selected.
Why selected/rejected for the role?
I think the clarity of concepts of both DSA as well as computer fundamentals that is OOPS, OS, and DBMS along with a proper grasp of the project you have done, also being Interview ready for HR questions were the skills that got me through.
Preparation
Duration: 12 Months
Topics: Two Pointers, Sliding windows, OOPS, Dynamic Programming, Graphs, Stacks, Queues
Tip
Tip

Tip 1: Do one major project and one medium project.

Tip 2: Solve at least 300+ coding questions.

Tip 3: Participate in mock interviews.

Application process
Where: Other
Eligibility: 2025 graduate
Resume Tip
Resume tip

Tip 1: Concise and important points should be bold.
Tip 2: Skills and projects should be properly written.

Interview rounds

01
Round
Medium
Online Coding Test
Duration90 minutes
Interview date20 Jun 2023
Coding problem3

It was in the evening around 6 PM and lasted for 90 minutes.

1. House Robber

Moderate
15m average time
80% success
0/80
Asked in companies
UberIntuitMicrosoft

You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed. All houses at this place are arranged in a circle. That means the first house is the neighbour of the last one. Meanwhile, adjacent houses have a security system connected, and it will automatically contact the police if two adjacent houses are broken into on the same night. Given an integer array nums representing the amount of money in each house, return the maximum amount of money you can rob tonight without alerting the police.

Problem approach

Intuition

Robbers have 2 choices either rob this house or the neighbouring house
The neighbourhood is designed circularly.
To fix this
first, we make him start from house no 2 up to the last house
next time we make him go from house 1 to the second last house
Since we are calculating every possibility we use recursion
To optimize the solution we use dp
Approach

The first and second move is where the robber goes from either 1st house to the second last or the second house to the last house.

Try solving now

2. Weighted Job Scheduling

Moderate
15m average time
85% success
0/80
Asked in companies
IntuitAmazonPhonePe

We have n jobs, where every job is scheduled to be done from startTime[i] to endTime[i], obtaining a profit of profit[I]. You're given the startTime, endTime and profit arrays, and return the maximum profit you can take such that there are no two jobs in the subset with overlapping time ranges. If you choose a job that ends at time X you will be able to start another job that starts at time X.

Problem approach

Use the array for the job with info (startTime, endTime, profit)

Sort the vector for the jobs[i]=(startTime[i], endTime[i], profit[i]).

Use the binary search (C++ upper_bound) to find the index next[i] for the target {jobs[i][1], 0, 0}={endTime[i], 0, 0} where endTime[i] is according to sorting.

Use DP to find the maximal profit

Try solving now

3. Three sum

Moderate
15m average time
85% success
0/80
Asked in companies
IntuitSamsungGrofers

Given an integer array nums, return all the triplets [nums[i], nums[j], nums[k]] such that i != j, i != k, and j != k, and nums[i] + nums[j] + nums[k] == 0. Notice that the solution set must not contain duplicate triplets.

Problem approach

Sort the input array
Initialize a set to store the unique triplets and an output vector to store the final result
Iterate through the array with a variable i, starting from index 0.
Initialize two pointers, j and k, with j starting at i+1 and k starting at the end of the array.
In the while loop, check if the sum of nums[i], nums[j], and nums[k] is equal to 0. If it is, insert the triplet into the set and increment j and decrement k to move the pointers.
If the sum is less than 0, increment j. If the sum is greater than 0, decrement k.
After the while loop, iterate through the set and add each triplet to the output vector.
Return the output vector

Try solving now
02
Round
Medium
Video Call
Duration60 minutes
Interview date6 Jul 2023
Coding problem4

The interview was scheduled for 10 AM and lasted for 60 minutes. The environment was quiet and peaceful. The interviewer was cooperative and helpful.

1. Container with Maximum Water

Easy
10m average time
90% success
0/40
Asked in companies
SalesforceMicrosoftAmazon

You are given an integer array height of length n. There are n vertical lines drawn such that the two endpoints of the ith line are (i, 0) and (i, height[I]). Find two lines that together with the x-axis form a container, such that the container contains the most water. Return the maximum amount of water a container can store. Notice that you may not slant the container.

Problem approach

The two-pointer technique starts with the widest container and moves the pointers inward based on the comparison of heights.
Increasing the width of the container can only lead to a larger area if the height of the new boundary is greater. By moving the pointers towards the centre, we explore containers with the potential for greater areas.

Try solving now

2. Operating System

Explain the Concept of Process in OS, Pillars of OOPS, and Virtual function.

Problem approach

Tip 1:Stay confident
Tip 2: Answer as much as you remember
Tip 3: Don't answer wrong

3. Polymorphism

4. Deadlock

What is deadlock and what are the conditions of deadlock? (Learn)

03
Round
Medium
Video Call
Duration60 minutes
Interview date6 Jul 2023
Coding problem2

Just 5 minutes after the first round ended, I received a call for the second round.

1. Tree Traversal Techniques

Explain all tree traversal techniques and which ones are better iterative or recursive. (Learn)

Problem approach

I explained all the 3 pre-order, in-order and post-order traversal of the tree firstly recursively and then iteratively and explained how the recursive approach takes extra stack space and is harder to debug.

2. DBMS

Given a scenario that a manager is alloted to many employees, how can that entity be assigned to many in tables?

Problem approach

Tip 1: Be thorough with the concepts
Tip 2: Be present and ask for inputs if necessary
Tip 3: Communicate

Here's your problem of the day

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

Skill covered: Programming

What is recursion?

Choose another skill to practice
Similar interview experiences
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Salesforce
1644 views
0 comments
0 upvotes
company logo
SDE - 1
4 rounds | 7 problems
Interviewed by Salesforce
3289 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 5 problems
Interviewed by Salesforce
1505 views
0 comments
0 upvotes
company logo
SDE - 1
2 rounds | 4 problems
Interviewed by Salesforce
1119 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
5 rounds | 12 problems
Interviewed by Amazon
114579 views
24 comments
0 upvotes
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Microsoft
57825 views
5 comments
0 upvotes
company logo
SDE - 1
3 rounds | 7 problems
Interviewed by Amazon
34961 views
7 comments
0 upvotes