168 questions · from 26 interviews · 2 asked more than once
Apple interview questions
Every question candidates reported from their Apple interviews, most frequently asked first. Each links to the write-up it came from, so you can see the round and how it went.
Apple coding and DSA questions
- 01
Trapping Rain Water
Solve the 'Trapping Rain Water' problem.
Hard · Asked 2 times · From Apple | IS&T | SWE | Hyd | Backend
- 02
Longest Common Prefix
Find the longest common prefix string amongst an array of strings.
Easy · Asked 2 times · From Apple Interview Experience | L4 | SDE 2 | Hyderabad
- 03
Check if undirected graph is bipartite (2‑colorable)
You are given an undirected graph with n nodes labeled from 0 to n - 1, and a list of edges where edges[i] = [u, v] denotes an undirected edge between node u and node v. Determine whether the graph can be colored using exactly 2 colors such that no two…
Medium · From Apple Interview - Full Stack Software Engineer
- 04
Validate Sudoku Board
Given a 9x9 Sudoku board, determine if it is valid. The board must satisfy Sudoku rules: each row, each column, and each of the nine 3x3 sub-grids contain no duplicate numbers (1-9). Empty cells are allowed.
Medium · From Apple interview experience - Full Stack Software engineer
- 05
Merge Overlapping Intervals
Given an array of intervals where each interval is represented as [start, end], merge all overlapping intervals and return an array of the merged intervals.
Medium · From Apple interview experience - Full Stack Software engineer
- 06
Minimum Runes to Add to Cast Spell
Given a grid representing runes, determine the minimum number of additional runes required to be able to cast a spell from the start cell to the target cell. You can move in the four cardinal directions (up, down, left, right). The goal is to find the least…
Hard · From Horrible and shocking interview experience with Apple IS&T team
- 07
Check Balanced Parentheses
Given a string consisting of parentheses characters '(' and ')', determine if the string is balanced, i.e., every opening parenthesis has a corresponding closing parenthesis in the correct order. Use a stack-based approach to validate the string.
From Apple SDE Interview Experience - Java, SpringBoot & Microservices role
- 08
Sum Iterator Parallelization
Given the class LongIterator implements Iterator { long val = 0; long max = 1000000; public boolean hasNext() {return val < max;} public long next() {return ++val;} }, write a driver function to calculate the sum of all values. Then parallelize the…
Medium · From Apple Interview Experience
- 09
Merge Two Employee Objects
Given two employee objects, you need to merge them into a single data structure. Which data structure would you choose and why? The candidate used a HashSet, explained equals/hashCode, and used a comparator.
Medium · From Apple Interview Experience
- 10
Parallel Car Production & Warehouse Slot Placement
Four threads produce cars in parallel and need to place them into a warehouse that has slots, where only one car can occupy a slot at a time. Write code for this scenario.
Medium · From Apple Interview Experience
- 11
Check Endianness of the Machine
Write a C program (or function) that determines whether the underlying system is little‑endian or big‑endian.
- 12
Implement Nested Checkbox Tree
Implement a nested checkbox tree component.
- 13
Generate Pretty Odd Statements
Given a nested list of strings, generate all possible "pretty odd statements" by taking one word from each inner list and concatenating them. The order of inner lists must be maintained. Input Example: { {"The", "A"}, {"dog","cat"}, {"runs","walks"},…
Medium · From Apple SSE Screening Round
- 14
Spiral Matrix (Vertical Variation)
A spiral matrix DSA question. Follow up: change the spiral from horizontal traversal to vertical traversal.
- 15
Subarray Sum Equals K
Given an integer array nums and an integer k, find all continuous subarrays whose sum is exactly equal to k.
Medium · From Apple Two-Round Pure Coding Interview Experience Round
- 16
Binary Tree Inorder Iterator
Design an iterator for inorder traversal of a binary tree, returning nodes in the order left → root → right, and you cannot store all nodes at once (must support lazy traversal).
Medium · From Apple Two-Round Pure Coding Interview Experience Round
- 17
Count Captured White Stones on a Board
Given a game board and a position (row, col) where a black stone is about to be placed, return the number of white stones captured by black. The board is represented as a 2D array of characters. Example: board = [ ['e', 'e', 'e', 'e', 'b', 'b', 'b'],…
Medium · From Apple ICT5 - Phone Screen
- 18
Convert Sorted Linked List to Balanced BST
Given a sorted linked list of integers, write a method(s) to create a balanced binary search tree from the list. Example: 1 - 2 - 5 - 6 - 8 - 10 - 19 Expected Output: 6 / \ 2 10 / \ / \ 1 5 8 19 Input : LinkedList head Output : TreeNode root
Medium · From Apple Phone Screen
- 19
Rotate a Matrix 90° Clockwise
Implement a function to rotate a given matrix 90 degrees clockwise directly in CoderPad.
- 20
Merge K Sorted Linked Lists
Discuss both brute-force (merging one at a time) and optimized approaches (using a min-heap / priority queue) for merging K sorted linked lists.
- 21
Maximum Length of a Mountain in an Array
Explain the logic and approach to find the maximum length of a mountain in an array.
- 22
Design LRU Cache
Explain the design of an LRU Cache using a HashMap and a Doubly Linked List to achieve O(1) operations.
- 23
Maximum Weight in Two Bags
This problem is a variation of the knapsack problem where the goal is to maximize the total weight of items selected for two separate bags, each with its own capacity constraint.
Hard · From Apple | Junior Software Engineer (ICT-2) | Offcampus
- 24
Grid Path Letter Collector
Given a 15x10 grid containing a unique path made of '' and lowercase letters. The path starts at (0,0), moves only in the four cardinal directions (no diagonals, forks, or loops), and ends at some point. I needed to follow this path, collect all lowercase…
Medium · From Apple | Junior Software Engineer (ICT-2) | Offcampus
- 25
Coin Change I
Given an array of coins with different denominations and a total amount of money, compute the fewest number of coins that are needed to make up that amount. If that amount cannot be made up by any combination of the coins, return -1.
Medium · From Apple | Junior Software Engineer (ICT-2) | Offcampus
31 more in the Apple write-ups.
Apple system design questions
- 01
Design Rate Limiter with Sliding Window using Redis
Verbally designing the rate limiter and from that how you will implement the sliding window algorithm. I chose Redis.
- 02
Logs Monitoring System Design
Design a system for collecting, storing, and monitoring logs from multiple services. Discuss components such as log ingestion, storage, real‑time querying, alerting, scalability, and reliability.
From Apple interview experience - Full Stack Software engineer
- 03
Design a Rate Limiter Function
Implement a function that limits the number of requests allowed per unit time. Discuss possible optimizations in both the logic (e.g., token bucket vs. leaky bucket) and implementation details.
From Apple SDE Interview Experience - Java, SpringBoot & Microservices role
- 04
Dynamic Pricing using Strategy Pattern
Design a system that calculates dynamic pricing using abstraction principles, specifically applying the Strategy pattern to allow interchangeable pricing algorithms.
From Apple SDE Interview Experience - Java, SpringBoot & Microservices role
- 05
Design a Video Upload System
Design a large‑scale video upload system similar to major media platforms. Cover aspects such as handling uploads, storage, retrieval, scaling, and reliability.
From Apple SDE Interview Experience - Java, SpringBoot & Microservices role
- 06
Service Downtime Mitigation
If after deployment your service goes down every 2 hours, what will you do?
- 07
Coffee Vending Machine Design
Design a coffee vending machine with steps such as pour milk, add sugar, add water, etc., and finally make coffee. Which design principle would you use to allow easy replacement of steps (e.g., replace sugar with coffee)?
- 08
Rate Limiter High‑Level Design
Provide a high‑level design of a rate limiter, including basic coding of the algorithm, placement in a distributed API gateway, handling cache failures, partitioning, and static vs dynamic configurations.
Hard · From Apple Interview Experience
- 09
Backup System Design
Design a backup system that ensures data integrity, scalability, multi‑region replication, observability, and resiliency.
Hard · From Apple Interview Experience
- 10
High-Performance Analytical Dashboard Design
Design a high-performance analytical dashboard capable of handling and visualizing large volumes of data.
Hard · From Apple Frontend Engineer screening round 1 & round 2
- 11
Design and Implement Todo Application
Design and implement a Todo application, starting with the data model and then building the application.
Medium · From Apple Frontend Engineer screening round 1 & round 2
- 12
High-Level Design of Spotify
High-level design of Spotify. Discuss the rationale behind using a relational database and why AWS S3 would be used.
- 13
Caching Principles
What is caching, and how does it improve performance?
- 14
- 15
Microservices Resiliency
Discuss microservices resiliency aspects, specifically mentioning rate limiting and circuit breaking.
- 16
Design BookMyShow
Design the BookMyShow system end-to-end, focusing on booking flow, onboarding of shows, searching nearby cinema halls, and analytics.
Hard · From Apple | IS&T | SWE | Hyd | Backend
- 17
Design TinyURL
Discuss the design of TinyURL. I explained two approaches: Base62 and MD5 Hash, along with their pros and cons.
Medium · From Apple | IS&T | SWE | Hyd | Backend
- 18
Scaling an Application from 100 to 1 Million RPS
Design a system to scale an application from 100 requests per second to 1 million requests per second.
Hard · From Apple | ICT3 | India | 2025 | Reject
- 19
Design a Scalable Subscription Form System
Design a robust system for 'Women Who Code' to circulate a subscription form that needs to handle access from billions of people and process subscription fees, ensuring wide-scale usage and scalability.
Hard · From Apple Interview Experience | L4 | SDE 2 | Hyderabad
- 20
Offline Payment System Design
Design a payment system that can function reliably even when internet connectivity is unavailable. Key considerations included security, distributed authority, and avoiding a single source of truth. We discussed concepts related to blockchain.
From Apple | Senior Software Engineer (ICT3) | Offer accepted
- 21
Real-time Event Messaging and Query System
Design a system that listens to messages from a data source related to various events (e.g., movie releases, sports events). Event types have different structures, requiring a flexible message format like JSON. The challenge is to design an efficient…
From Apple | Senior Software Engineer (ICT3) | Offer accepted
- 22
Design Snake Game
Design a Snake game that is played on a width x height grid. The snake initially occupies the top left corner (0,0) and its length is 1. When a piece of food is eaten, the snake's length increases by 1. Design a SnakeGame class.
Medium · From Apple | Senior Software Engineer (ICT3) | Offer accepted
- 23
Online Block Diagram Maker App Design
Design an online application for creating block diagrams. The system should support real-time updates for multiple concurrent users and manage an 'infinite' canvas size efficiently.
From Apple | Senior Software Engineer (ICT3) | Offer accepted
- 24
Real-time Asset Price Propagation System Design (DAG)
Design a system for managing and propagating asset price changes. Changes in one asset's price should trigger updates in related assets based on predefined, weighted dependency relationships modeled as a Directed Acyclic Graph (DAG). The system must…
From Apple | Senior Software Engineer (ICT3) | Offer accepted
- 25
Design a DigiYatra-like Application
Develop the system design for an application similar to DigiYatra, which focuses on providing a seamless, paperless travel experience using facial recognition technology.
From Apple | Senior Software Engineer (ICT3) | Offer accepted
1 more in the Apple write-ups.
Apple behavioural and HR questions
- 01
Resolving Peer Conflicts
How do you resolve conflicts with your peer?
- 02
Convincing Lead on Design and Pushback
Tell me a time when you proposed a design to your lead and had to convince him/her that it would fulfill the usecase? How do you pushback when someone is not convinced?
- 03
Giving Feedback to Junior Team Members
How do you give feedback to your junior team members?
- 04
Using GenAI Tools for Efficiency
What GenAI tools do you use in your day-to-day life? How does it improve your efficiency?
- 05
- 06
Implementing Features with Unfamiliar Technology
Describe any recent project that you worked on, where you had to implement the feature using a technology that you were not familiar with? How was the learning curve?
- 07
Project Discussion and Technical Challenges
Introduce yourself and explain one of your projects in detail, particularly focusing on technical challenges faced, how issues were debugged, and the overall impact of your project.
- 08
Teamwork without Guidance
Describe times when you worked in a team without sufficient guidance.
- 09
Handling Communication Gaps and Progress
How did you handle communication gaps and ensure consistent progress in a team setting?
- 10
Innovative Solutions in Projects
Describe instances where you came up with innovative solutions in any of your projects.
- 11
Dealing with Setbacks and Achieving Results
How did you deal with setbacks and ensure successful outcomes despite challenges?
- 12
- 13
Behavioral: Disagreement with Peer
Tell me a time when you had a disagreement with a peer.
- 14
Behavioral: Delivering in Short Time
Tell me a time when you delivered in a short time and reprioritized work.
- 15
Behavioral: New Technology Adoption
Tell me a time when you used some new technology in a project.
- 16
Motivation for Work
What excites you to come to work everyday?
- 17
Behavioral Questions: Workplace Challenges & Leadership Disagreements
I was asked behavioral questions covering my experiences with challenges encountered at work and how I handled disagreements with leadership.
From Apple | Senior Software Engineer (ICT3) | Offer accepted
- 18
Behavioral Questions & Past Projects Discussion
This hiring manager round focused on discussions about my past projects and various behavioral questions, similar to the 2022 hiring manager round.
From Apple | Senior Software Engineer (ICT3) | Offer accepted
- 19
Team Conflict Resolution
Describe a difficult situation you experienced with team members and how you successfully resolved it.
- 20
Handling Work Mistakes
Share an experience where you made a mistake at work and explain the steps you took to fix it.
Apple other questions
- 01
Kafka Consumer Down / Producer Continues Producing
Producer is producing messages, but the consumer is down. Messages will keep accumulating. Kafka brokers have finite memory/storage. What can we do to mitigate this?
- 02
Optimized website loading strategies
What are the optimized ways used for the loading of the website like Amazon.com or Flipkart.com if opened in incognito mode?
- 03
JavaScript threading and event loop
Is JavaScript Multithreaded or Single Threaded? What is the event loop? Is the working of JS top‑to‑down or vice‑versa?
- 04
Handling large data rendering in UI
In JavaScript, if we fetch a huge data set (e.g., 10 million records) through an API and render it in a UI table, what will break on the UI and how can we resolve it?
- 05
Output of setTimeout loop with var
What is the output of the following code? javascript for (var i = 0; i { console.log(i) }, 0) }
- 06
Difference between var and let
Explain the difference between the var and let keywords in JavaScript.
- 07
Closures in JavaScript
What are closures in JavaScript? Provide an example.
- 08
Temporal Dead Zone in JavaScript
What is the Temporal Dead Zone (TDZ) in JavaScript?
- 09
Implement collapsible tree with +/- button in React
Implement a component that renders a tree structure (provided JSON data) with expandable/collapsible nodes using +/- buttons. javascript import React, { useState } from 'react' import './App.css' // Sample data structure provided in the interview const data =…
- 10
Difference between setTimeout and setInterval
Explain the difference between setTimeout and setInterval in JavaScript.
- 11
HTML defer attribute usage
What is the defer attribute in HTML? Can it be used with the img tag as well?
- 12
Debug Kernel Module Deadlock
Given a kernel module that contains a deadlock, identify the cause of the deadlock and suggest possible optimizations.
- 13
Debugging Production Frontend Issues
Discuss strategies for debugging production issues in frontend applications.
- 14
Core Web Vitals Explanation
Explain Core Web Vitals metrics, specifically CLP, LCP, and INP.
- 15
Render-Blocking Resources and Performance
Discuss render-blocking resources and their impact on web application performance.
- 16
Cross-Browser Compatible CSS
Describe approaches to writing cross-browser compatible CSS.
- 17
Zustand vs. Redux Comparison
Provide a comparison between Zustand and Redux state management libraries.
- 18
React Table with Pagination
Given some data in an array with 5 rows, create a table and fetch data for each row. Follow up: include next and prev button with pagination.
- 19
O(1) Space Complexity Definition
What does O(1) space complexity mean?
- 20
O(log n) vs O(n) Time Complexity
Explain the difference between O(log n) and O(n) time complexity, providing real-world examples.
- 21
DNS Resolution Process
Describe the process that occurs when you search for google.com in a browser, covering DNS queries.
- 22
Necessity of Communication Protocols
Explain why protocols are necessary in communication.
- 23
- 24
- 25
React useContext Output and Hooks Deep Dive
The interviewer showed a small React code snippet involving the useContext API. I was asked to predict the output and explain the reasoning. Follow-up questions covered React hooks: useContext (its use in prop drilling and state management) and useMemo &…
41 more in the Apple write-ups.
Apple interview questions FAQ
What questions are asked in Apple interviews?
Candidates reported 168 distinct questions across 26 Apple interviews. 56 coding and DSA questions, 26 system design questions, 20 behavioural and HR questions, 66 other questions.
Which Apple interview questions are asked most often?
The most repeated are "Trapping Rain Water" (2 times), "Longest Common Prefix" (2 times).
How difficult are Apple interview questions?
Of the questions candidates rated, 12% were easy, 65% medium and 23% hard.