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

SDE - 1

Scaler
upvote
share-icon
3 rounds | 5 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 4 months
Topics: C, C++, Java, Data Structures, Pointers, OOPS, System Design, Algorithms, Dynamic Programming, Networking, Operating System
Tip
Tip

Tip 1 : You need a strong aptitude for knowledge as a first tip
Tip 2 : Solve questions from previous coding questions
Tip 3 : Make sure your resume includes at least two projects

Application process
Where: Referral
Eligibility: None
Resume Tip
Resume tip

Tip 1 : Have at least 2 good projects mentioned in your resume with a link
Tip 2 : Focus on skills, internships, projects, and experiences.
Tip 3 : Make it simple, crisp, and one page

Interview rounds

01
Round
Medium
Online Coding Test
Duration60 mins
Interview date1 Nov 2021
Coding problem2

This was technical round in which they gave me two coding question which need to be solved in one hour.

1. Remove Duplicates from Sorted Array

Easy
15m average time
85% success
0/40
Asked in companies
WalmartAppleCognizant

You are given a sorted integer array 'arr' of size 'n'.


You need to remove the duplicates from the array such that each element appears only once.


Return the length of this new array.


Note:
Do not allocate extra space for another array. You need to do this by modifying the given input array in place with O(1) extra memory. 


For example:
'n' = 5, 'arr' = [1 2 2 2 3].
The new array will be [1 2 3].
So our answer is 3.
Problem approach

Time complexity = O(n) + time taken by erase function.
Space complexity = O(1)

class Solution {
public:
int removeDuplicates(vector& nums) {
int cnt = 1;
for(int i=1; i if(nums[i]!=nums[i-1]){
cnt++;
}
else{
nums.erase(nums.begin()+i);
i=i-1; // to keep i in the same place after performing the deletion.
}
}
return cnt;
}
};

Try solving now

2. All Unique Permutations

Easy
15m average time
85% success
0/40
Asked in companies
AppleGoogleFacebook

You are given an array Arr consisting of N integers. Your task is to find all the unique permutations of the given array. For e.g if the array is {1, 1, 2}, the unique permutations of this array are {1, 1, 2}, {1, 2, 1}, {2, 1, 1}. Note that the total number of permutations of {1,1,2} is equal to 6 but out of those {1,1,2} and {1,2,1} occur twice.

Note:
1. There might be duplicates present in the array.
2. The order of the permutations in the output does not matter.
3. Do not use any kind of in-built library functions to find the answer.
Problem approach

Basic backtrack solution

class Solution {
List> result;

public List> permute(int[] nums) {
result = new ArrayList<>();

backtrack(nums, new ArrayList());
return result;
}

public void backtrack(int[] nums, List curr) {
if (curr.size() == nums.length) {
result.add(new ArrayList(curr));
return;
}

for (int i = 0; i < nums.length; i++) {
if (!curr.contains(nums[i])) {
curr.add(nums[i]);
backtrack(nums, curr);
curr.remove(curr.size() - 1);
}
}
}
}

Try solving now
02
Round
Medium
Video Call
Duration60 mins
Interview date2 Nov 2021
Coding problem2

This was technical round taken by the SDE1 at scaler based on problem solving and data structures

1. Spiral Matrix

Easy
0/40
Asked in companies
AdobeAccentureCisco

You are given a N x M matrix of integers, return the spiral path of the matrix

Example Of Spiral Path

Spiral Path

Problem approach

Solution in Java

class Solution {
public List spiralOrder(int[][] matrix) {
int m = matrix.length, n = matrix[0].length;
int up = 0, down = m-1, left = 0, right = n-1;

List res = new LinkedList<>();

while (res.size() < m * n) {
// top: left to right
if (up <= down) {
for (int i = left; i <= right; i++) {
res.add(matrix[up][i]);
}
up++;
}

// right: up to down
if (left <= right) {
for (int i = up; i <= down; i++) {
res.add(matrix[i][right]);
}
right--;
}

// bottom: right to left
if (up <= down) {
for (int i = right; i >= left; i--) {
res.add(matrix[down][i]);
}
down--;
}

// left: down to up
if (left <= right) {
for (int i = down; i >= up; i--) {
res.add(matrix[i][left]);
}
left++;
}
}

return res;
}
}

Try solving now

2. Valid Number

Hard
15m average time
85% success
0/120
Asked in companies
FacebookScalerVFISLK Global Services

You are given a string, ‘S’. You have to tell whether this string is a valid number or not. If the string is valid print “Valid” else print “Invalid” without quotes.

A number is said to be valid if it can be split in the following two components: i) A decimal number or an integer ii) (Optional) An 'e' or 'E', followed by an integer.

A decimal number can be split up into these components (in order): i) (Optional) A sign character (either '+' or '-') ii) One of the following formats: At least one digit, followed by a dot '.' or At least one digit, followed by a dot '.', followed by at least one digit. or A dot '.', followed by at least one digit.

An integer can be split up into these components (in order): i) (Optional) A sign character (either '+' or '-') ii) At least one digit.

Problem approach

At first I thought it was as trivial as using regular expressions but then I thought about it and it's actually easier than that.
Just convert string to float and check whether it passes.
Every programming language already has a function that verifies whether a string is a valid number!
If this is an interview question, it would test your creativity much more than your coding skills.

class Solution:
def isNumber(self, s: str) -> bool:
if 'inf' in s.lower():
return False
try:
float(s)
return True
except:
return False

Try solving now
03
Round
Medium
HR Round
Duration60 minutes
Interview date4 Nov 2021
Coding problem1

This was technical + HR round taken by senior Manager and HR of the Scaler

1. Basic HR Questions

Tell me about yourself
Tell me about the most challenging project
What do you know about scaler
Tell me about the basic pillars of OOPs
How will you merge the sorted linkedlist
what are acid properties
Am I ready to relocate to any location in India
Why should we hire you
How will you resolve conflict with your manager
Will you join us if you got offer from Amazon ?

Problem approach

Tip 1: Make sure your resume is up-to-date
Tip 2: Be confident and focus on your communication
Tip 3: Prepare for the behavioral questions

Here's your problem of the day

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

Skill covered: Programming

Which keyword is used for inheritance?

Choose another skill to practice
Similar interview experiences
company logo
SDE - 1
4 rounds | 8 problems
Interviewed by Amazon
7532 views
0 comments
0 upvotes
Analytics Consultant
3 rounds | 10 problems
Interviewed by ZS Associates
779 views
0 comments
0 upvotes
company logo
SDE - Intern
1 rounds | 3 problems
Interviewed by Amazon
2895 views
0 comments
0 upvotes
company logo
SDE - 2
4 rounds | 6 problems
Interviewed by Expedia Group
2226 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
5 rounds | 12 problems
Interviewed by Amazon
113401 views
24 comments
0 upvotes
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Microsoft
56894 views
5 comments
0 upvotes
company logo
SDE - 1
3 rounds | 7 problems
Interviewed by Amazon
34499 views
6 comments
0 upvotes