Upload Button Icon Add office photos

Filter interviews by

Trading Technologies SDE-2 Interview Questions and Answers

Be the first one to contribute and help others!

Interview questions from similar companies

SDE-2 Interview Questions & Answers

Amazon user image Anonymous

posted on 9 Dec 2024

Interview experience
5
Excellent
Difficulty level
-
Process Duration
-
Result
-
Round 1 - Coding Test 

Hacker Rank test - 4 rounds (Coding, System Design and Work style assessment, Leadership Principles)

Round 2 - Technical 

(2 Questions)

  • Q1. LC - 2 medium difficulty questions
  • Q2. System design discussion

SDE-2 Interview Questions & Answers

Mphasis user image CodingNinjas

posted on 17 Dec 2021

I was interviewed in Aug 2021.

Round 1 - Video Call 

(4 Questions)

Round duration - 45 minutes
Round difficulty - Medium

Technical Interview round that lasted for about 45 minutes. Questions were based on Java, Java design Patterns and OOPS Concepts.

  • Q1. Java Question

    What are static methods in Interfaces?

  • Ans. 

    Static methods are useful for designing utility methods since they contain method implementation that is owned by the interface and invoked using the interface name. They cannot be overridden.

  • Answered by CodingNinjas
  • Q2. Java Question

    Why was a new version of Java (Java 8) needed in the first place? (

  • Ans. 

    There are two primary reasons for this:
    1. Due to significant developments in hardware, Java now needs to make better use of multi-core CPUs.
    2. Make new Functional Programming (FP) features available to users.

  • Answered by CodingNinjas
  • Q3. Java Question

    What is a default method, and when does it get used?

  • Ans. 

    The default method is found in the interface and involves an implementation. The technique extends an interface's functionality while maintaining backward compatibility with existing classes that implement the interface.

  • Answered by CodingNinjas
  • Q4. Java Question

    Describe in how many ways can you create a singleton pattern?

  • Ans. 

    There are two ways of creating a Singleton pattern.
    1. Early Instantiation : It is responsible for the creation of instance at load time.
    2. Lazy Instantiation : It is responsible for the creation of instance when required.

  • Answered by CodingNinjas
Round 2 - Video Call 

(4 Questions)

Round duration - 60 minutes
Round difficulty - Medium

Technical Interview round that lasted for about 45 minutes. Questions were based on Spring boot and Microservices Concepts.

  • Q1. Java Question

    Difference between Bridge Pattern and Adapter Button

  • Ans. 

    The motive of the Adapter pattern is to make interfaces of one or more classes to look similar. The Bridge pattern is designed to isolate a class's interface from its implementation so we can vary or substitute the implementation without changing the client code.

  • Answered by CodingNinjas
  • Q2. SpringBoot Question

    What is the difference between @RestController and @Controller in Spring Boot?

  • Ans. 

    @Controller Map of the model object to view or template and make it human readable but @RestController simply returns the object and object data is directly written in HTTP response as JSON or XML.

  • Answered by CodingNinjas
  • Q3. Technical Question

    Difference between Spring and Spring Boot

  • Ans. 

    1. Spring framework is a java EE framework that is used to build applications. Spring Boot framework is mainly used to develop REST API’s
    2. The primary feature of the Spring framework is dependency injection. The main feature of the Spring Boot is Autoconfiguration. 
    3. The goal pf Spring is to make Java EE (Enterprise Edition) development easier, allowing developers to be more productive. Spring Boot provides the ...

  • Answered by CodingNinjas
  • Q4. Technical Question

    Difference between Monolithic and Microservices Architecture

  • Ans. 

    Monolithic Architecture: It is "like a big container" where all the software components of an application are bundled together tightly. It is usually built as one large system and is one code-base. 
    Microservice Architecture: It involves structuring an application in the form of a cluster of small, autonomous services modeled around a business domain. The functional modules can be deployed independently, are scalab...

  • Answered by CodingNinjas
Round 3 - HR 

(1 Question)

Round duration - 30 minutes
Round difficulty - Easy

This was a typical HR round with some standard Behavioral questions

  • Q1. Basic HR Question

    Why should we hire you ?

  • Ans. 

    Tip 1 : The cross questioning can go intense some time, think before you speak.
    Tip 2 : Be open minded and answer whatever you are thinking, in these rounds I feel it is important to have opinion.
    Tip 3 : Context of questions can be switched, pay attention to the details. It is okay to ask questions in these round, like what are the projects currently the company is investing, which team you are mentoring. How all is the...

  • Answered by CodingNinjas

Interview Preparation Tips

Eligibility criteriaAbove 7 CGPAMphasis interview preparation:Topics to prepare for the interview - Java, Spring Boot Framework, Data Structures, Algorithms, System Design, OOPSTime required to prepare for the interview - 3 monthsInterview preparation tips for other job seekers

Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.

Application resume tips for other job seekers

Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.

Final outcome of the interviewSelected

Skills evaluated in this interview

SDE-2 Interview Questions & Answers

Cisco user image CodingNinjas

posted on 21 Mar 2022

I was interviewed before Mar 2021.

Round 1 - Coding Test 

(2 Questions)

Round duration - 60 minutes
Round difficulty - Medium

2 coding question both and 15 MCQ

Only C , Java , Python are allowed

  • Q1. Minimum steps to reach target by a Knight

    You have been given a square chessboard of size ‘N x N’. The position coordinates of the Knight and the position coordinates of the target are also given.

    Your t...

  • Ans.  Using BFS

    The idea is to perform BFS traversal. Start from the initial position of the Knight and proceed to further cells. Traversal is performed using a queue. The queue stores the different paths travelled by the knight and also keeps storing the count of steps. When the target is popped from the queue, the corresponding count of the steps is the answer.

     

    1. Define a class with the following data members
        &nbs...
  • Answered by CodingNinjas
  • Q2. Maximum Size Rectangle Sub-matrix With All 1's

    You are given an 'N' * 'M' sized binary-valued matrix 'MAT, where 'N' is the number of rows and 'M' is the number of colum...

  • Ans. Dynamic Programming.
    1. We start from the first row and move downwards.
    2. We create three 1-dimensional arrays HEIGHT[], LEFT[], RIGHT[].
    3. ‘HEIGHT’[i]: stores the number of current continuous 1’s in column i.
    4. LEFT[i] : stores the leftmost index ‘j’ such that all indices say ‘K’, ‘K’ belongs to [j, i], ‘HEIGHT’[k] >= ‘HEIGHT’[i].
    5. RIGHT [i]: stores the rightmost index ‘j’ such that all indices say ‘K’, ‘K’ belongs to [i, j], ‘HE...
  • Answered by CodingNinjas
Round 2 - Video Call 

(6 Questions)

Round duration - 45 minutes
Round difficulty - Easy

Around 6 am morning
2 interviewers

  • Q1. Reverse Linked List
    Input Format :
    The first line of input contains a single integ...
  • Ans. Recursive Approach

    One way is to use recursion to reverse the list. Divide the linked list in two halves, the first node and the rest of the list. Reverse the second half using recursion and append the first half, that is the first node at the end of the reversed linked list. Return the head of the reversed linked list.

     

    Algorithm

     

    • If the list contains only one node, return the head of the list.
    • Else, divide the ...
  • Answered by CodingNinjas
  • Q2. OS Question

    Synchronization in Operating System in detail

  • Ans. 

    Tip 1 : Go through Semaphore extremely important 

  • Answered by CodingNinjas
  • Q3. Networking Question

    Osi model with example at each layer transfer

  • Ans. 

    Tip 1 : they will ask question in between make sure u explain it in very detail and give example live like how this interview is happening online with each layer playing its role.

  • Answered by CodingNinjas
  • Q4. Networking Question

    What is NAT router?

  • Ans. 

    Tip 1 : Network address translation router

  • Answered by CodingNinjas
  • Q5. Technical Question

    How do beat Google if u want to make a search engine?

  • Ans. 

    Tip 1 : I took this question to system design horizontal and vertical scaling which they agreed

  • Answered by CodingNinjas
  • Q6. Puzzle

    Total water in earth ?

  • Ans. 

    Tip 1 : I said that i know earth radius , will calculate its surface area and multiple with average depth of water bodies in earth , they didn't respond.

  • Answered by CodingNinjas
Round 3 - Video Call 

(1 Question)

Round duration - 30 minutes
Round difficulty - Easy

Manager Round

  • Q1. Puzzle

    It was all on my master's thesis

  • Ans. 

    Tip 1 : Make sure if u project is working put its link preferably video of the working project my project was on ML and IOT and I put a Video link .

  • Answered by CodingNinjas
Round 4 - HR 

(2 Questions)

Round duration - 10 Minutes
Round difficulty - Easy

Salary breakdown and Location preference

  • Q1. Basic HR Question

    Are u satisfied with the salary breakup?

  • Q2. Basic HR Question

    Location preferences: banglore, chennai, Pune

Interview Preparation Tips

Eligibility criteriaNoneCisco interview preparation:Topics to prepare for the interview - Computer Network Gate CS Level, Operating System college Level, Array and Linked List, Dynamic Programming, DFS and BFSTime required to prepare for the interview - 3 monthsInterview preparation tips for other job seekers

Tip 1 : Computer Network should be strong
Tip 2 : Exposure to system programming also helps
Tip 3 : At least 150 problems and C++ was not allowed so prepare accordingly

Application resume tips for other job seekers

Tip 1 : Project should be really good
Tip 2 : Write Computer Network and Operating System Courses in resume as course taken

Final outcome of the interviewSelected

Skills evaluated in this interview

SDE-2 Interview Questions & Answers

Amazon user image Anonymous

posted on 3 Sep 2024

Interview experience
5
Excellent
Difficulty level
Moderate
Process Duration
4-6 weeks
Result
Not Selected

I applied via Company Website and was interviewed in Mar 2024. There were 2 interview rounds.

Round 1 - Coding Test 

Amazon Online assessment which consisted of 2 coding DSA medium question

Round 2 - One-on-one 

(3 Questions)

  • Q1. Question related to TreeMap
  • Q2. Question related BFS
  • Q3. System Design - Design Feed system

Interview Preparation Tips

Interview preparation tips for other job seekers - Be ready to answer questions in 25 minuted both coding and system design

SDE-2 Interview Questions & Answers

Amazon user image Anonymous

posted on 6 Jul 2022

Round 1 - Coding Test 

Diameter of a binary tree and bfs and dfs questions

Round 2 - Coding Test 

Data structure and algorithms

Round 3 - Technical 

(1 Question)

  • Q1. System design questions

Interview Preparation Tips

Interview preparation tips for other job seekers - Prepare data structure well and system design

SDE-2 Interview Questions & Answers

Amazon user image Anonymous

posted on 18 Apr 2022

Round 1 - Resume Shortlist 
Pro Tip by AmbitionBox:
Keep your resume crisp and to the point. A recruiter looks at your resume for an average of 6 seconds, make sure to leave the best impression.
View all tips
Round 2 - One-on-one 

(1 Question)

  • Q1. Behavioural questions related to leadership principle.

Interview Preparation Tips

Interview preparation tips for other job seekers - Nothing specific, respond back based on your experience

SDE-2 Interview Questions & Answers

Amazon user image CodingNinjas

posted on 16 Sep 2021

I was interviewed in Apr 2021.

Round 1 - Video Call 

(1 Question)

Round duration - 60 Minutes
Round difficulty - Medium

Timing: 10AM-11AM
Interviewer was quite supportive and helpful.
Environment was normal as usual and it was morning time

  • Q1. Application Question

    Design a system where user can upload, delete and share the video/image files. 
    And can immediately view the uploaded files on the different logged-in system

Round 2 - Video Call 

(2 Questions)

Round duration - 60 Minutes
Round difficulty - Medium

Timing: 11AM-12PM
The interviewer was SDE2
He was checking the code for edge cases and was hinting if required

  • Q1. Implement a priority queue

    Ninja is given a task to implement a priority queue using Heap data structure. The Ninja is busying preparing for the tournament., So he asked for your help.

    Your task is to us...

  • Ans. Array representation of heap

     

    1. Since the heap is maintained in the form of a complete binary tree, the heap can be easily represented in the form of an array.
    2. To keep the tree complete and shallow, while inserting a new element insert it in the leftmost vacant position in the last level i.e., at the end of our array, and perform some operation to maintain the property of the heap.
    3. Similarly, for deleting the maximum e...
  • Answered by CodingNinjas
  • Q2. Ninja and the bulbs

    Ninja owns an electronic shop. In the shop, Ninja has 'N' bulbs. To sell these bulbs, Ninja has to check if they are of good quality. To check bulbs, Ninja uses a unique techniq...

  • Ans.  Brute Force

    Approach:

    A brute force solution to this problem is to turn on and off the bulbs N time, then at last check the number of bulbs that are on.


     

    Algorithm:

    • Take a boolean array of ‘BULBS’ of size N+1.
    • Itertate on ‘i’ from 1 to ‘N’
      • Iterate on ‘j’ form ‘i’ to ‘N’ and each time increment ‘j’ as ‘j’ += ‘i’.
        • if(BULBS[j] == true) then make it false.
        • If (BULBS[j]==false) then make it true.
    • Intialise a variable ‘COUNT’ =...

  • Answered by CodingNinjas
Round 3 - Video Call 

(1 Question)

Round duration - 60 Minutes
Round difficulty - Medium

Timing: 6PM-7PM
The interviewer was not interactive and didn't gave any feedback whatsoever.
It was Hiring Manager Round
Interviewer was Software Development Manager at Amazon

  • Q1. Maximize the sum

    You are given two sorted arrays of distinct integers, ‘ARR1’ and ‘ARR2’. If you find a common element in both arrays, you can switch from one array to another.

    Your task is to find a pat...

  • Ans. Recursive

    In this problem, our primary focus is on the common elements i.e. an element that is present in both the arrays. Then, we have to decide whether we have to make a switch. So for that, first we store all the elements of ‘ARR1’ and ‘ARR2’ into ‘MAP1’ and ‘MAP2’ respectively. 

     

    Now we call our ‘maximiseSumHelper’ function. We call this function for both cases i.e starting with ‘ARR1’ and starting with ‘A...

  • Answered by CodingNinjas

Interview Preparation Tips

Professional and academic backgroundI completed Computer Science Engineering from A. C. Patil College of Engineering. I applied for the job as SDE - 2 in BangaloreEligibility criteriaAbove 2 years of experienceAmazon interview preparation:Topics to prepare for the interview - Linkedlist, BST, Heap, Queue, Pointers, Binary SearchTime required to prepare for the interview - 2 MonthsInterview preparation tips for other job seekers

Tip 1 : Focus on internals of Data structure on how it actually works
Tip 2 : Implement the Data Structure from scratch, later you can use the inbuilt packages no problem but you must know the implementation
Tip 3 : Understand System Design concepts

Application resume tips for other job seekers

Tip 1 : Highlight your contributions you made and how it impacted the business and be real
Tip 2 : Mention the improvement figures like x% reduction in page load size, improved SEO ranking by x figure, reduce memory usage by y%

Final outcome of the interviewRejected

Skills evaluated in this interview

SDE-2 Interview Questions & Answers

Amazon user image CodingNinjas

posted on 16 Sep 2021

I was interviewed in Apr 2021.

Round 1 - Telephonic Call 

(2 Questions)

Round duration - 60 minutes
Round difficulty - Easy

Started with brief intro(5 mins) about interviewer.
Problem solving question, question was already there in the codelink shared by the interviewer. He explained the problem again with sample testcase. 
The Interviewer was friendly.

  • Q1. Course Schedule II

    You have been given ‘N’ courses and some courses may have prerequisites. Now consider a matrix ‘PREREQUISITES’ of size 'M' x 2 which represents that you must complete course '...

  • Ans. Breadth-First Search

    Our current algorithm is based on the idea of the BFS approach. We first process all the courses with 0 in-degree implying no prerequisite courses required. If we remove all these courses from the graph, along with their outgoing edges, we can find out the courses/nodes that should be processed next. These would again be the nodes with 0 in-degree. We can continuously do this until all the courses h...

  • Answered by CodingNinjas
  • Q2. System Design

    System design a live video broadcast platform.

Round 2 - Video Call 

(2 Questions)

Round duration - 90 minutes
Round difficulty - Medium

There were 2 interviewers(India HM and Seattle HM), India HM was just shadowing and didn't ask any questions. Started with intro, he asked in detail about what I do at current company(10 mins). Again, jumped into LP's(25 mins).

  • Q1. Distance between two nodes of a Tree

    Given a binary tree and the value of two nodes, find the distance between the given two nodes of the Binary Tree.

    Distance between two nodes is defined as the minimum...

  • Ans. Naive Approach

    In any rooted tree, the distance between two nodes 'U' and 'V' can be found by finding the lowest common ancestor (LCA), ‘x’ of two nodes. The lowest common ancestor (LCA) between nodes 'U' and 'V' is defined as the lowest node in the tree that has both 'U' and 'V' as descendants, where we define each node to be a descendant of itself (so if 'U' has a direct connection from 'V', 'V' is the lowest common a...

  • Answered by CodingNinjas
  • Q2. Median in a stream

    Given that integers are read from a data stream. Your task is to find the median of the elements read so far.

    Median is the middle value in an ordered integer list. If the size of the ...

  • Ans. Brute force approach

    Store the incoming data elements in a vector. Sort the vector everytime you need to output the median.

    Algorithm:

    1. Store the incoming elements of the data stream in a vector.
    2. Step by step insert one element and sort the vector as soon as any element is added in the vector.
    3. If the size of the vector is odd, print the middle element of the sorted vector.
      If the size of the vector is even, return the mean of...
  • Answered by CodingNinjas
Round 3 - Telephonic Call 

(1 Question)

Round duration - 60 minutes
Round difficulty - Medium

There was only 1 interviewer in this round and We had no video sharing in this round so it was becoming difficult to understand each other.

  • Q1. Object Oriented Design Question

    Started with brief intro about both(5 mins), then he jumped into LP's(25 mins). This was very difficult since there was no video and he was grilling me real hard on this, so...

Interview Preparation Tips

Professional and academic backgroundI applied for the job as SDE - 2 in SeattleEligibility criteriaNAAmazon interview preparation:Topics to prepare for the interview - Data Structures - Trie, HashMap, Sets, Priority Queue, Stack, Advanced Topics like Fenwick Tree, Segment Trees, Game Theory, Dynamic Programming, Union Find,Graph Algorithms, BitmaskingTime required to prepare for the interview - 3 monthsInterview preparation tips for other job seekers

Tip 1 : Bookmark the GFG Amazon Archives. It helped me a lot during my preparations. Reading other’s interview experiences is one of the best ways to get yourselves ready for the next job interview. Practice daily atleast 5 questions.
Tip 2 : Most commonly asked topics in Amazon Interviews ( as per the mail I received from my recruiter ) :
BFS/DFS/Flood fill, Binary Search, Tree traversals, Hash tables, Linked list, stacks, queues, two pointers/sliding window
Binary heaps, Ad hoc/string manipulations.
Tip 3 : Highly recommended sites for practicing questions ( usually practice medium and hard level questions) :
Leetcode (highly encouraged)
Geeksforgeeks (highly encouraged)
CodeZen( highly encouraged)
Codeforces
Tip 4 : This is a great bigocheatsheet that could be of great help https://www.bigocheatsheet.com/

Application resume tips for other job seekers

Tip 1 : Mention past working experience in detail as how you were important to your previous company.
Tip 2 : Try to keep your resume to 1 page if work experience < 5 years
Tip 3 : Update your resume according to role you are applying for and never put false things on resume.

Final outcome of the interviewRejected

Skills evaluated in this interview

SDE-2 Interview Questions & Answers

Amazon user image CodingNinjas

posted on 16 Sep 2021

I was interviewed in Mar 2021.

Round 1 - Coding Test 

(2 Questions)

Round duration - 45 minutes
Round difficulty - Medium

This round was scheduled in the evening hours and all the participants were required to fill a form which was shared 15 minutes prior to the start of the online coding round. This form was filled out probably for the security reasons and to ensure that no one disinterested participant gives the test.

  • Q1. Ways To Make Coin Change

    You are given an infinite supply of coins of each of denominations D = {D0, D1, D2, D3, ...... Dn-1}. You need to figure out the total number of ways W, in which you can make a cha...

  • Ans. Recursion

     

    1. The idea is to use recursion.
    2. For a particular coin, we have two options either include it or exclude it.
    3. If we include that coin, then calculate the remaining number that we have to generate so recur for that remaining number.
    4. If we exclude that coin, then recur for the same amount that we have to make.
    5. Our final answer would be the total number of ways either by including or excluding.
    6. There will be two edg...
  • Answered by CodingNinjas
  • Q2. Validate BST

    You have been given a binary tree of integers with N number of nodes. Your task is to check if that input tree is a BST (Binary Search Tree) or not.

    A binary search tree (BST) is a binary tr...

  • Ans. BST property

    The approach is based on the fact that the value of each node in a BST is greater than the value of all the nodes in the left subtree and smaller than the value of all the nodes in the right subtree.

     

    Here is the complete algorithm-

    • For each node, we store the minimum and maximum value allowed for that node. Initially, for the root node, the minimum value would be -10^9 and the maximum value should be 10...
  • Answered by CodingNinjas
Round 2 - Telephonic Call 

(1 Question)

Round duration - 60 minutes
Round difficulty - Hard

This round was on call where I was just supposed to answer the tech questions that were asked. It started with a brief interview with one another and then moved to questions on DBMS, operating systems, computer networks and all. Almost 20-25 questions were asked and I probably answered 90% of them correctly.

  • Q1. Reverse Linked List
    Input Format :
    The first line of input contains a single integ...
  • Ans. Recursive Approach

    One way is to use recursion to reverse the list. Divide the linked list in two halves, the first node and the rest of the list. Reverse the second half using recursion and append the first half, that is the first node at the end of the reversed linked list. Return the head of the reversed linked list.

     

    Algorithm

     

    • If the list contains only one node, return the head of the list.
    • Else, divide the ...
  • Answered by CodingNinjas
Round 3 - HR 

(1 Question)

Round duration - 30 minutes
Round difficulty - Hard

There was only one interviewer for this round. He continuously interacted with me and was giving me some good situational problems that were not very easy to answer. Basically those were open-minded questions which can be answered oth ways and that's why I found it quiet hard as per my nature but at the end things went well for me.

  • Q1. Basic Puzzles

    A noticeable aspect in this puzzles is the fact that there’s a circular misplacement, which implies if apple is wrongly labelled as Apple, Apple can’t be labelled as Orange, i.e., it has to be...

  • Ans. 

    Note: basically it's better if you have seen some puzzles before any HR round since they will give you an idea of what kind of problem you may encounter and then you can ace any difficult to difficult HR interview.

  • Answered by CodingNinjas

Interview Preparation Tips

Professional and academic backgroundI completed Mechanical Engineering from Malaviya National Institute of Technology Jaipur. I applied for the job as SDE - 2 in HyderabadEligibility criteriaabove 7 cgpa, no backlogsAmazon interview preparation:Topics to prepare for the interview - Data Structures, hashmap, linked list, Pointers, OOPS, System Design, Algorithms, Dynamic Programming, array, 2-pointer problemsTime required to prepare for the interview - 8 monthsInterview preparation tips for other job seekers

Tip 1 : practice on gfg and coding ninjas
Tip 2 : compete on codechef and codeforces
Tip 3 : learn DSA and practice regularly

Application resume tips for other job seekers

Tip 1 : put your entire valuable experience in brief
Tip 2 : put the handle of you competitive coding profiles
Tip 3 : try to put those things that really attracts the recruiter, will be better if your past experiences relates to the company

Final outcome of the interviewSelected

Skills evaluated in this interview

SDE-2 Interview Questions & Answers

Amazon user image CodingNinjas

posted on 16 Sep 2021

I was interviewed in Oct 2020.

Round 1 - Coding Test 

(2 Questions)

Round duration - 90 minutes
Round difficulty - Easy

I got a call from an Amazon recruiter regarding the schedule of the test . She sent me the coding test link which I had to complete within a week. we can attempt the online test anytime, when we have time for a period of 90 minutes at a stretch.Once I completed the test, I got a call to schedule the interviews in two weeks.

  • Q1. Shopping Options

    You are given the list of costs of pants in an array “pants”, shirts in an array “shirts”, shoes in an array “shoes”, and skirts in an array “skirts”. You are also given a budget amount ‘X...

  • Ans. Brute Force

    We can check all possible combinations to buy items. That can be done by maintaining a variable “answer” and iterating over all four lists in a nested way such that each pant, shirt, shoe, and skirt pair can get selected and find the sum of that pair. If sum is less than or equal to budget then increment “answer” by one. Return the “answer”.


    Algorithm:

     

    • Create an integer “answer” equal to 0.
    • First iterate ...

  • Answered by CodingNinjas
  • Q2. Max Submatrix

    Ninja has been given a matrix ‘MAT’ of integers having size ‘N’ x ‘M’ i.e. N rows and M columns. Ninja has to find the maximum sum submatrix in it. In other words, he has to find the maximum ...

  • Ans. Brute Force

    The brute force approach is we check for every possible submatrix in the given ‘MAT’.

    • 4 nested loops are required to select every submatrix of the matrix.
    • 2 nested loops are required to take the sum of all the elements of the submatrix.

    Here is the algorithm :

    1. We declare a variable ‘MAX_SUM’ in which we store the maximum sum over all submatrices in the matrix.
    2. We run a loop for ‘i’ = 0 to ‘N’:
      • We run a loop for ‘j...
  • Answered by CodingNinjas
Round 2 - Video Call 

(2 Questions)

Round duration - 60 minutes
Round difficulty - Medium

Virtual interview occured in amazon chime.The interviewer gave his introduction, asked me a bit on the kind of projects I’ve worked on. Then he started with a data structure problem.

  • Q1. Clone a binary tree with random pointers.

    You are given a binary tree. Apart from the left and right child pointers, each node in the given binary tree points to a random node in the given binary tree. You...

  • Ans. HashMap based approach

    The idea is to use a HashMap to map the tree nodes to each clone node. We will traverse the binary tree and create a clone tree with the random pointer equal to NULL and map each node of the given tree to its clone node. Now we will again iterate through the tree and add the random pointer of each node by looking up the HashMap. 

     

    The steps are as follows:

    1. Let’s define a HashMap to map eac...
  • Answered by CodingNinjas
  • Q2. Ninja Port

    Ninja is stuck in a city with ‘N’ colonies, and each colony contains ‘K’ houses. Ninja is currently at the house number “sourceHouse” present in the colony with colony number “sourceColony”. He ...

  • Ans. Breadth First Search

    We can initially create a graph with 2 nodes from each colony i.e. the first and last house of each colony would be included in the graph. We also create an edge from the node representing the last node of each colony to the node representing the first node of the next colony, and vice versa.
     

    Now, we add into the graph each house that has an outgoing or incoming secret path. We also make edges ...

  • Answered by CodingNinjas
Round 3 - Video Call 

(1 Question)

Round duration - 75 Minutes
Round difficulty - Easy

This was taken by an engineering manager who asked me regarding my projects for around 10-15 mins and then we moved to a system design problem. He asked me to design Slack messenger.
I started by listing the functional and non-functional requirements(on which he questioned me a bit), then I moved to draw the high-level architecture. The components which I drew were the clients, gateway service(LB + authentication, etc), Messaging Service, User Service, Web Socket Manager service, Fan Out service(I added this for the group messages thing, but he didn’t interrogate much on that).

He asked me what would be the schema of my messages table and the scenarios in which the recipient user is online/offline.Also asked about the partitioning key and primary key of the 2-3 tables which I had made

  • Q1. Technical Questions

    This was taken by an SDE III guy, who again asked me about my projects for like 10 mins and then moved on to a low level design question.He asked me to design the HackerRank platform.
    Aga...

Round 4 - Video Call 

(2 Questions)

Round duration - 60 minutes
Round difficulty - Hard

BarRaiser Round

This was again taken by an engineering manager who discussed my projects in depth for around 20-25 mins. In the remaining time he asked me 2 dsa questions. (Yes I too was surprised that he didn’t ask anything regarding design).

In almost all the rounds, I was asked questions related to Amazon Leadership principles, so do make sure you go through those before sitting for the interview process. You can refer to this link(https://www.codingninjas.com/codestudio/problem-lists/top-amazon-coding-interview-questions) for practicing the same, I found it useful. 
In the design rounds, interviewer doesn’t expect the most ideal answer from you and unless your choice of technology is outrageously wrong, he won’t pinpoint that.

  • Q1. Group Anagrams Together

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

  • Ans. Sorting based Approach

    The idea behind this approach is that two or more than two strings are anagrams if and only if their sorted strings are equal. So we will use a HashMap, let’s say “anagramGroup”, where each key is a sorted string, and the key will be mapping to the list of indices from the given list of strings that form a group of anagrams. This means that if we sort the strings at those indices, we will get the ...

  • Answered by CodingNinjas
  • Q2. Add Linked Lists

    Given two numbers represented by linked lists. Your task is find the sum list and return the head of the sum list.

    The sum list is a linked list representation of addition of two numbers...

  • Ans. Recursive approach

    One way is to recursively add the two linked lists. Keep the nodes in the recursion stack and add the last nodes first and then second last and so on. Initially, find the size of both the linked lists. If both the linked lists are of the same size, add them using recursion. Else if their sizes differ, move the head pointer of the larger linked list forward K times, where K is the difference between th...

  • Answered by CodingNinjas

Interview Preparation Tips

Professional and academic backgroundI completed Computer Science Engineering from Sathyabama Institute Of Science And Technology. I applied for the job as SDE - 2 in HyderabadEligibility criteriaNo CGPA criteriaAmazon interview preparation:Topics to prepare for the interview - Data Structures and Algorithms, OOPS concepts, cpp, operating systems, dbmsTime required to prepare for the interview - 3 monthsInterview preparation tips for other job seekers

Tip 1 : Expect questions related to Amazon Leadership principles in all rounds, so go through those thoroughly before sitting for the interview process.
Tip 2 : In the design rounds, interviewer doesn’t expect the most ideal answer from you and unless your choice of technology is outrageously wrong, he won’t pinpoint that.
Tip 3 : Data Structures questions are a must in all rounds, so try to master them thoroughly

Application resume tips for other job seekers

Tip 1 : Make sure you know everything you mention in your resume
Tip 2 : Have some hands on with hackathons and contests ,which brings an added value to your resume

Final outcome of the interviewRejected

Skills evaluated in this interview

Tell us how to improve this page.

Interview Questions from Similar Companies

Accenture Interview Questions
3.9
 • 8k Interviews
Amazon Interview Questions
4.1
 • 5k Interviews
Capgemini Interview Questions
3.8
 • 4.7k Interviews
HCLTech Interview Questions
3.5
 • 3.7k Interviews
Teleperformance Interview Questions
3.9
 • 1.7k Interviews
Mphasis Interview Questions
3.4
 • 787 Interviews
Nagarro Interview Questions
4.0
 • 761 Interviews
View all
Software Engineer
12 salaries
unlock blur

₹12 L/yr - ₹28 L/yr

Senior Software Engineer
10 salaries
unlock blur

₹30 L/yr - ₹53.5 L/yr

Software Developer
5 salaries
unlock blur

₹17 L/yr - ₹25 L/yr

Senior Test Engineer
5 salaries
unlock blur

₹14 L/yr - ₹20 L/yr

Software Quality Engineer
4 salaries
unlock blur

₹8.5 L/yr - ₹14.8 L/yr

Explore more salaries
Compare Trading Technologies with

Interactive Brokers

3.5
Compare

Oanda Corporation

4.8
Compare

Zerodha

4.2
Compare

Upstox

3.7
Compare

Calculate your in-hand salary

Confused about how your in-hand salary is calculated? Enter your annual salary (CTC) and get your in-hand salary
Did you find this page helpful?
Yes No
write
Share an Interview