FastPrepSubset Sum Possible
Problems/Subset Sum Possible

Subset Sum Possible

Apple logoApple● MediumNEW GRADPHONE SCREENONSITE INTERVIEW

Updated Nov 2026

QuestionFunctionExamples

Problem statement

Source note: This problem is backed by an Apple Round 1 question post. The post directly asks whether a subset can reach a target and shows a backward dynamic-programming update that uses each element at most once, but it did not include examples or constraints. The core task match is about 95%.

You are given an integer array arr and an integer target. Return true if some subset of arr has sum exactly target; otherwise return false.

Each array element may be used at most once.

Function

isSubsetSum(arr: int[], target: int) → boolean

Examples

Example 1

arr = [3,34,4,12,5,2]target = 9return = true

The subset [4,5] sums to 9.

More Apple Onsite Interview questions

  • LRU CachePHONE SCREEN · ONSITE INTERVIEW · Seen Dec 2026
  • Topological OrderingPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • Merge IntervalsOA · PHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
  • FIFO Mutex Operation TraceONSITE INTERVIEW · Seen Oct 2026
  • Implement Hit CounterPHONE SCREEN · ONSITE INTERVIEW · Seen Oct 2026
  • Parse Nested HTML into a TreeONSITE INTERVIEW · Seen Oct 2026
  • Thread-Safe Concurrent Linked ListONSITE INTERVIEW · Seen Sep 2026
  • Palindrome Match PercentageONSITE INTERVIEW · Seen Sep 2026
  • Binary Tree Nodes at Distance KONSITE INTERVIEW · Seen Aug 2026
  • BST to Sorted Circular Doubly Linked ListONSITE INTERVIEW · Seen Aug 2026

Similar questions at other companies

  • Maximum Sum with K-Element SkippingPhonePe · ONSITE INTERVIEWPhonePe interview questions
  • Assign Escalations to TeamsAmazon · ONSITE INTERVIEW
  • Maximum Subarray Sum with One DeletionServiceNow · PHONE SCREENServiceNow interview questions
  • Distinct Subset SumsGoogle · ONSITE INTERVIEWGoogle interview questions
  • Maximum Product of a Contiguous SubarrayLinkedIn · PHONE SCREENLinkedIn interview questions
  • Count Subsets With a Target SumSafe Security · ONSITE INTERVIEW
  • Fewest Coins CombinationBloomberg LP · PHONE SCREENBloomberg LP interview questions
  • Longest Increasing SubsequenceByteDance · PHONE SCREENByteDance interview questions
  • Jump GamePaytm · PHONE SCREENPaytm interview questions
  • Maximum Subarray Sum with One DeletionOracle · ONSITE INTERVIEWOracle interview questions

Apple interview experiences

  • Apple SWE Phone Screen: Subarray Products: 1 Experience
  • Apple New Grad SWE Java, Coding and Manager Rounds: 1 Experience
  • Apple AI Coding and Related Interviews: 17 Experiences
  • Apple India SWE New Grad Interviews: 5 Experiences
  • Apple New Grad SWE Phone Screens: 12 Experiences (Part 3 of 3)
  • Apple New Grad SWE and Embedded: 16 Experiences (Part 2 of 3)
All Apple interview questionsSee Apple hiring insights
Saved
class Solution {
    public boolean isSubsetSum(int[] arr, int target) {
      // write your code here
    }
}
Checking account…