Code360 powered by Coding Ninjas X Naukri.com. Code360 powered by Coding Ninjas X Naukri.com
Apple interview experience Real time questions & tips from candidates to crack your interview

SDE - 1

Apple
upvote
share-icon
3 rounds | 6 Coding problems

Interview preparation journey

expand-icon
Journey
Break the question down into smaller independent parts Visualize the problem by drawing it out don’t jump to write the code. Real Life problem-solving in your projects. Always have both individual and group projects on my resume.
Application story
I came to BITS campus placements and applied there, Application with google forms. Process was big and took lot of time to get results=
Why selected/rejected for the role?
Quick learning skills and projects I made during graduation. Multi-Domain projects are better the single ones. (Ex:- ML inside your web app). Real Life problem-solving in your projects is much more appreciated than in a college project. Consistency is the key as simple to say but very hard to apply.
Preparation
Duration: 2 months
Topics: Data Structures, ReactJS, OOPS, System Design, Algorithms, Dynamic Programming, Graphs.
Tip
Tip

Tip 1: Don't sit silently and code, explain to the interviewer your approach and each step.
Tip 2: Take help from the interviewer don't treat him like a villain(he is there to help you)
Tip 3: Understand the patterns, it will help you choose the data structure easily

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

Tip 1: Give links for every project, live or Github link (it will make your work authentic)
Tip 2: Make your resume concise and easy to scan (1 page)

Interview rounds

01
Round
Medium
Online Coding Test
Duration60 mins
Interview date11 Mar 2021
Coding problem2

DSA coding questions were asked

1. Merge Intervals

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

You are given N number of intervals, where each interval contains two integers denoting the start time and the end time for the interval.

The task is to merge all the overlapping intervals and return the list of merged intervals sorted by increasing order of their start time.

Two intervals [A,B] and [C,D] are said to be overlapping with each other if there is at least one integer that is covered by both of them.

For example:

For the given 5 intervals - [1, 4], [3, 5], [6, 8], [10, 12], [8, 9].

Since intervals [1, 4] and [3, 5] overlap with each other, we will merge them into a single interval as [1, 5].

Similarly, [6, 8] and [8, 9] overlap, merge them into [6,9].

Interval [10, 12] does not overlap with any interval.

Final List after merging overlapping intervals: [1, 5], [6, 9], [10, 12].
Problem approach

This problem can be solved with a linear scan algorithm. The list of input intervals is given, and we’ll keep merged intervals in the output list. For each interval in the input list:

Try solving now

2. Clone Graph

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

You are given a reference/address of a node in a connected undirected graph containing N nodes and M edges. You are supposed to return a clone of the given graph which is nothing but a deep copy. Each node in the graph contains an integer “data” and an array/list of its neighbours.

The structure of the graphNode class is as follows:

class graphNode 
{  
    public:
        int data;
        vector<graphNode*> neighbours;
}
Note :
1. Nodes are numbered from 1 to N.

2. Your solution will run on multiple test cases. If you are using global variables make sure to clear them.
Problem approach

We use depth first traversal and create a copy of each node while traversing the graph. Use a hashtable to store each completed node so we won’t revisit nodes that exist in that hashtable. The hashtable key will be a node in the original graph, and its value will be the corresponding node in the cloned graph.

Try solving now
02
Round
Medium
Video Call
Duration60 mins
Interview date15 Apr 2021
Coding problem2

The manager just asked me one DSA question, mostly resume and my projects

1. Check Identical Trees

Moderate
20m average time
85% success
0/80
Asked in companies
MakeMyTripMicrosoftDisney + Hotstar

You are given two binary trees with 'n' and 'm' nodes respectively.


You need to return true if the two trees are identical. Otherwise, return false.


Example:
For the trees given below:- 

example

The given trees are identical as:-
1. The number of nodes in both trees is the same. 
2. The number of edges in both trees is the same. 
3. The data for root for both the trees is the same i.e 5. 
4. The data of root -> left (root’s left child) for both the trees is the same i.e 2.
5. The data of root -> right (root’s right child) for both the trees is the same i.e 3.
6. The data of root -> right -> left ( left child of root’s right child) for both the trees is the same i.e 6.
7. Nodes with data 2 and 6 are the leaf nodes for both the binary trees. 
Problem approach

Use a depth-first traversal on both trees simultaneously and keep comparing the data at each level to solve this problem.

Try solving now

2. Project based Questions

Tell me about your projects.

03
Round
Medium
HR Round
Duration45 mins
Interview date22 Apr 2021
Coding problem2

1. Basic HR Questions

Conflict management in projects

Problem approach

Tip 1: Create a technology summary section in addition to your skills section.
Tip 2 Include collegial education information including CPGA and PORs.

2. Basic HR Question

Introduce yourself

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 write a single-line comment in C++?

Choose another skill to practice
Start a Discussion
Similar interview experiences
company logo
SDE - 1
3 rounds | 4 problems
Interviewed by Apple
1857 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 5 problems
Interviewed by Apple
0 views
0 comments
0 upvotes
company logo
Intern
2 rounds | 3 problems
Interviewed by Apple
2132 views
0 comments
0 upvotes
company logo
SDE - 1
4 rounds | 10 problems
Interviewed by Apple
2210 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
5 rounds | 12 problems
Interviewed by Amazon
104643 views
24 comments
0 upvotes
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Microsoft
49760 views
5 comments
0 upvotes
company logo
SDE - 1
3 rounds | 7 problems
Interviewed by Amazon
31028 views
6 comments
0 upvotes