← Apple roles

Interview question tracker

Apple Coding Interview Questions — All time

Practice 452 coding questions from Apple company-tagged LeetCode lists across all available reporting periods. Explore reported interview questions and track your progress.

Company-wide data from Fahad7177-jeh/leetcode-company-wise-questions; see its AGPL-3.0 license. All-time questions also use dataengineervishal/leetcode-companywise-questions (MIT license).

Reporting periods reflect source data, not verified interview dates. Questions can recur; inclusion does not guarantee they will appear in your interview.

Updated weekly · Latest source check: ⓘLatest successful check of the sources used by this company. A check does not necessarily mean the questions changed.

One question at a time.

Top questions 452

DoneQuestionLeetCode
LRU CacheSolve
Two SumSolve
Best Time to Buy and Sell StockSolve
Group AnagramsSolve
Longest Common PrefixSolve
Longest Substring Without Repeating CharactersSolve
Merge IntervalsSolve
Number of IslandsSolve
Rotate ArraySolve
Course ScheduleSolve
Kth Largest Element in an ArraySolve
Maximum SubarraySolve
Median of Two Sorted ArraysSolve
Merge Sorted ArraySolve
Product of Array Except SelfSolve
Reverse IntegerSolve
Reverse Linked ListSolve
Reverse Words in a StringSolve
Rotate ImageSolve
Spiral MatrixSolve
Top K Frequent ElementsSolve
Trapping Rain WaterSolve
Valid PalindromeSolve
Valid ParenthesesSolve
Valid SudokuSolve
3SumSolve
Add Two NumbersSolve
Best Time to Buy and Sell Stock IISolve
Binary Tree Level Order TraversalSolve
Climbing StairsSolve
Compare Version NumbersSolve
Container With Most WaterSolve
Course Schedule IISolve
Create Hello World FunctionSolve
Design Circular QueueSolve
Design Hit CounterSolve
Fibonacci NumberSolve
Find First and Last Position of Element in Sorted ArraySolve
Find the Index of the First Occurrence in a StringSolve
Insert Delete GetRandom O(1)Solve
Insert IntervalSolve
Integer to English WordsSolve
Longest Consecutive SequenceSolve
Longest Palindromic SubstringSolve
Lowest Common Ancestor of a Binary TreeSolve
Meeting Rooms IISolve
Merge k Sorted ListsSolve
Merge Two Sorted ListsSolve
Min StackSolve
Move ZeroesSolve
Number of 1 BitsSolve
Palindrome NumberSolve
Pascal's TriangleSolve
Remove Duplicates from Sorted ArraySolve
Remove Nth Node From End of ListSolve
Reverse BitsSolve
Roman to IntegerSolve
Search a 2D Matrix IISolve
Search in Rotated Sorted ArraySolve
Sqrt(x)Solve
String CompressionSolve
Subarray Sum Equals KSolve
Valid AnagramSolve
Word BreakSolve
Add BinarySolve
Array NestingSolve
Assign CookiesSolve
Asteroid CollisionSolve
Basic Calculator IISolve
Best Time to Buy and Sell Stock with Transaction FeeSolve
Binary Tree PathsSolve
Calculate Score After Performing InstructionsSolve
Coin ChangeSolve
Contains DuplicateSolve
Count the Number of Incremovable Subarrays ISolve
Count the Number of Incremovable Subarrays IISolve
Decode StringSolve
Delete Node in a Linked ListSolve
Design HashMapSolve
Design Tic-Tac-ToeSolve
Find K Closest ElementsSolve
Find Median from Data StreamSolve
Find Peak ElementSolve
Find Servers That Handled Most Number of RequestsSolve
Find the Grid of Region AverageSolve
Find Winner on a Tic Tac Toe GameSolve
First Unique Character in a StringSolve
Fizz BuzzSolve
Flatten Nested List IteratorSolve
Generate ParenthesesSolve
Happy NumberSolve
House RobberSolve
House Robber IISolve
Implement Queue using StacksSolve
Implement Trie (Prefix Tree)Solve
Interleaving StringSolve
Intersection of Two ArraysSolve
Isomorphic StringsSolve
Jump GameSolve
Largest Rectangle in HistogramSolve
Letter Combinations of a Phone NumberSolve
Majority ElementSolve
Max Points on a LineSolve
Maximal SquareSolve
Maximum Depth of Binary TreeSolve
Maximum Rows Covered by ColumnsSolve
Merge Strings AlternatelySolve
Middle of the Linked ListSolve
Number of Pairs of Strings With Concatenation Equal to TargetSolve
Number of Squareful ArraysSolve
Peeking IteratorSolve
PermutationsSolve
Random Pick with WeightSolve
Ransom NoteSolve
Regular Expression MatchingSolve
Remove All Adjacent Duplicates In StringSolve
Reverse Linked List IISolve
Reverse StringSolve
Rotting OrangesSolve
Search a 2D MatrixSolve
Search Insert PositionSolve
Serialize and Deserialize Binary TreeSolve
Set Matrix ZeroesSolve
Simplify PathSolve
Sliding Window MaximumSolve
Snapshot ArraySolve
String to Integer (atoi)Solve
Subarray Product Less Than KSolve
Task SchedulerSolve
Time Based Key-Value StoreSolve
Two Sum II - Input Array Is SortedSolve
Unique Number of OccurrencesSolve
Valid Palindrome IISolve
Validate Binary Search TreeSolve
Wildcard MatchingSolve
Word LadderSolve
Word SearchSolve
4SumSolve
Accounts MergeSolve
Apple Redistribution into BoxesSolve
Arithmetic Slices II - SubsequenceSolve
Average Selling PriceSolve
Bag of TokensSolve
Balanced Binary TreeSolve
Best Time to Buy and Sell Stock IVSolve
Binary SearchSolve
Binary Tree Maximum Path SumSolve
Binary Tree Vertical Order TraversalSolve
Can Place FlowersSolve
Cheapest Flights Within K StopsSolve
Check If Two String Arrays are EquivalentSolve
Combination SumSolve
Copy List with Random PointerSolve
Count PrimesSolve
Customer Who Visited but Did Not Make Any TransactionsSolve
Delete and EarnSolve
Design Add and Search Words Data StructureSolve
Diameter of Binary TreeSolve
Distribute Money to Maximum ChildrenSolve
Divide Two IntegersSolve
Evaluate Reverse Polish NotationSolve
Exam RoomSolve
Find All Anagrams in a StringSolve
Find All Duplicates in an ArraySolve
Find Customer RefereeSolve
Find Minimum in Rotated Sorted ArraySolve
First Bad VersionSolve
First Missing PositiveSolve
Flood FillSolve
Furthest Building You Can ReachSolve
Gas StationSolve
Greatest Common Divisor of StringsSolve
H-IndexSolve
Intersection of Two Linked ListsSolve
Island PerimeterSolve
Jump Game IISolve
K Closest Points to OriginSolve
Koko Eating BananasSolve
Kth Smallest Element in a Sorted MatrixSolve
LFU CacheSolve
Longest Repeating Character ReplacementSolve
Lowest Common Ancestor of a Binary Search TreeSolve
Lowest Common Ancestor of a Binary Tree IIISolve
Maximum Number of Operations With the Same Score IISolve
Maximum Path Quality of a GraphSolve
Meeting RoomsSolve
Minimize Deviation in ArraySolve
Minimum Number of Arrows to Burst BalloonsSolve
Minimum Number of Operations to Make Array EmptySolve
Minimum Remove to Make Valid ParenthesesSolve
Minimum Window SubstringSolve
Missing NumberSolve
Next Greater Element ISolve
Next Greater Element IISolve
Palindrome Linked ListSolve
Palindrome PartitioningSolve
Palindromic SubstringsSolve
Path Sum IIISolve
Perfect SquaresSolve
Permutations IISolve
Plus OneSolve
Power of TwoSolve
Product of the Last K NumbersSolve
Rearrange Array Elements by SignSolve
Recyclable and Low Fat ProductsSolve
Remove Duplicates from Sorted ListSolve
Remove ElementSolve
Reorder ListSolve
Rotate ListSolve
Sequential DigitsSolve
Single Element in a Sorted ArraySolve
Single NumberSolve
Snakes and LaddersSolve
Sort Characters By FrequencySolve
Sort ColorsSolve
Sort ListSolve
Split Array Largest SumSolve
Squares of a Sorted ArraySolve
SubsetsSolve
Sum of Subarray MinimumsSolve
Symmetric TreeSolve
Text JustificationSolve
The Skyline ProblemSolve
Transpose MatrixSolve
Valid Word AbbreviationSolve
Validate IP AddressSolve
Verifying an Alien DictionarySolve
Word PatternSolve
Zigzag ConversionSolve
01 MatrixSolve
Add Two IntegersSolve
Alien DictionarySolve
All Nodes Distance K in Binary TreeSolve
Angle Between Hands of a ClockSolve
Apply Operations to Make Sum of Array Greater Than or Equal to kSolve
Array PartitionSolve
Article Views ISolve
Average Waiting TimeSolve
Backspace String CompareSolve
Basic CalculatorSolve
Best Poker HandSolve
Best Time to Buy and Sell Stock IIISolve
Best Time to Buy and Sell Stock with CooldownSolve
Binary Search Tree IteratorSolve
Binary Subarrays With SumSolve
Binary Tree Inorder TraversalSolve
Binary Tree Preorder TraversalSolve
Binary Tree Right Side ViewSolve
Binary Tree Zigzag Level Order TraversalSolve
Boats to Save PeopleSolve
Capacity To Ship Packages Within D DaysSolve
Clone GraphSolve
Coin Change IISolve
CombinationsSolve
Complement of Base 10 IntegerSolve
Concatenated WordsSolve
Construct Binary Tree from Preorder and Inorder TraversalSolve
Contains Duplicate IISolve
Contiguous ArraySolve
Continuous Subarray SumSolve
Convert an Array Into a 2D Array With ConditionsSolve
Convert Sorted Array to Binary Search TreeSolve
Count and SaySolve
Count Complete Tree NodesSolve
Count Subarrays Where Max Element Appears at Least K TimesSolve
Count Subarrays With Fixed BoundsSolve
Count Symmetric IntegersSolve
CounterSolve
Custom Sort StringSolve
Customers Who Bought All ProductsSolve
Daily TemperaturesSolve
Decode WaysSolve
Delete Duplicate EmailsSolve
Delete Nodes And Return ForestSolve
Delete the Middle Node of a Linked ListSolve
Department Top Three SalariesSolve
Design Browser HistorySolve
Design In-Memory File SystemSolve
Design Log Storage SystemSolve
Design Search Autocomplete SystemSolve
Design TwitterSolve
Determine if Two Strings Are CloseSolve
Diagonal Traverse IISolve
Difference Between Ones and Zeros in Row and ColumnSolve
Dot Product of Two Sparse VectorsSolve
Edit DistanceSolve
Employee Free TimeSolve
Find All Lonely Numbers in the ArraySolve
Find All Numbers Disappeared in an ArraySolve
Find Largest Value in Each Tree RowSolve
Find Pivot IndexSolve
Find the Duplicate NumberSolve
Find the Highest AltitudeSolve
Find the Pivot IntegerSolve
Find Words That Can Be Formed by CharactersSolve
First Letter to Appear TwiceSolve
Flatten Deeply Nested ArraySolve
Game of LifeSolve
Game Play Analysis ISolve
Goat LatinSolve
Guess the WordSolve
Hand of StraightsSolve
HeatersSolve
Image SmootherSolve
Immediate Food Delivery IISolve
Implement Stack using QueuesSolve
Insert Delete GetRandom O(1) - Duplicates allowedSolve
Integer to RomanSolve
Intersection of Three Sorted ArraysSolve
Is SubsequenceSolve
Jewels and StonesSolve
Jump Game VIISolve
K-diff Pairs in an ArraySolve
Keyboard RowSolve
Keys and RoomsSolve
Knight Probability in ChessboardSolve
Kth Missing Positive NumberSolve
Largest Divisible SubsetSolve
Largest NumberSolve
Least Number of Unique Integers after K RemovalsSolve
Length of Last WordSolve
Length of Longest Subarray With at Most K FrequencySolve
Letter Case PermutationSolve
Linked List CycleSolve
Linked List Cycle IISolve
Logger Rate LimiterSolve
Longest Absolute File PathSolve
Longest Common SubsequenceSolve
Longest Harmonious SubsequenceSolve
Longest Increasing Subsequence IISolve
Longest Subsequence With Limited SumSolve
Longest Substring with At Most K Distinct CharactersSolve
Magnetic Force Between Two BallsSolve
Make The String GreatSolve
Managers with at Least 5 Direct ReportsSolve
Max Chunks To Make SortedSolve
Max Chunks To Make Sorted IISolve
Max Consecutive OnesSolve
Max Consecutive Ones IIISolve
Maximal RectangleSolve
Maximize Distance to Closest PersonSolve
Maximum Average Subarray ISolve
Maximum Frequency StackSolve
Maximum Length of Pair ChainSolve
Maximum Population YearSolve
Maximum Product Difference Between Two PairsSolve
Maximum Product of Three NumbersSolve
Maximum Product SubarraySolve
Maximum Profit in Job SchedulingSolve
Maximum Width of Binary TreeSolve
Minimize Maximum Component CostSolve
Minimum Difficulty of a Job ScheduleSolve
Minimum Increment to Make Array UniqueSolve
Minimum Knight MovesSolve
Minimum Length of String After Deleting Similar EndsSolve
Minimum Number of Steps to Make Two Strings AnagramSolve
Minimum Number of Taps to Open to Water a GardenSolve
Minimum Path SumSolve
Minimum Size Subarray SumSolve
Minimum Speed to Arrive on TimeSolve
Missing RangesSolve
N-QueensSolve
Nested List Weight SumSolve
Next PermutationSolve
Nth DigitSolve
Number of AtomsSolve
Number of Changing KeysSolve
Number of Connected Components in an Undirected GraphSolve
Number of Good PairsSolve
Number of Matching SubsequencesSolve
Odd Even Linked ListSolve
Online Stock SpanSolve
Optimize Water Distribution in a VillageSolve
Out of Boundary PathsSolve
Pairs of Songs With Total Durations Divisible by 60Solve
Palindrome PermutationSolve
Partition Array According to Given PivotSolve
Partition Array for Maximum SumSolve
Path SumSolve
Permutation in StringSolve
Pow(x, n)Solve
Rabbits in ForestSolve
Range Sum Query - ImmutableSolve
Read N Characters Given Read4Solve
Read N Characters Given read4 II - Call Multiple TimesSolve
Reconstruct ItinerarySolve
Rectangle AreaSolve
Remove Duplicates from Sorted List IISolve
Remove K DigitsSolve
Remove Linked List ElementsSolve
Remove Zero Sum Consecutive Nodes from Linked ListSolve
Reorganize StringSolve
Repeated DNA SequencesSolve
Restore IP AddressesSolve
Reveal Cards In Increasing OrderSolve
Reverse Nodes in k-GroupSolve
Reverse PairsSolve
Reverse Vowels of a StringSolve
Reverse Words in a String IISolve
Rising TemperatureSolve
Robot Bounded In CircleSolve
Rotate StringSolve
Running Sum of 1d ArraySolve
Same TreeSolve
Search in a Binary Search TreeSolve
Search Suggestions SystemSolve
Second Highest SalarySolve
Short Encoding of WordsSolve
Shortest BridgeSolve
Shortest Distance from All BuildingsSolve
Shortest Path in a Grid with Obstacles EliminationSolve
Shortest Word DistanceSolve
Shuffle StringSolve
Similar String GroupsSolve
SleepSolve
Sliding Window MedianSolve
Sort an ArraySolve
Sort Array By ParitySolve
Spiral Matrix IIISolve
Split Strings by SeparatorSolve
String Compression IIISolve
Students and ExaminationsSolve
Subarray Sums Divisible by KSolve
Subsets IISolve
Substring with Concatenation of All WordsSolve
Sudoku SolverSolve
Sum of Square NumbersSolve
Sum of Subarray RangesSolve
Sum of Two IntegersSolve
Summary RangesSolve
Super PowSolve
Surrounded RegionsSolve
Swap Nodes in PairsSolve
Target SumSolve
The kth Factor of nSolve
Third Maximum NumberSolve
Top K Frequent WordsSolve
Trapping Rain Water IISolve
Tree DiameterSolve
Tree NodeSolve
TriangleSolve
Ugly NumberSolve
Unique Binary Search TreesSolve
Unique Email AddressesSolve
Valid NumberSolve
Valid Parenthesis StringSolve
Valid Perfect SquareSolve
Valid Word SquareSolve
Walking Robot SimulationSolve
Web Crawler MultithreadedSolve
Word Ladder IISolve
Word Pattern IISolve