Facebook | Phone | Word break II & Combination Sum
Difficulty: MEDIUMCategory: InterviewExperienceFrequency: 1Asked On 2020-05-12Added By Anonymous
Source: Link
Company: Meta (Facebook)
Role: unknown
Interview Stage: Phone Screen
Location: unknown
Year: unknown
Original Post Content:
Given a string without spaces. Insert spaces in it based on a given dictionary..
https://leetcode.com/problems/word-break-ii/ - did this in 20 mins
Given an array, check whether there are any contiguous or non-contiguous sub-arrays whose sum is equal to target.
https://leetcode.com/problems/combination-sum-ii/ (return true instead returning a list) - "bombed"
Even though I know combination sum problem, I completely failed to think in that direction during the time of interview..my bad
Reject the next day..
Learnt some lessons with this interview..keep coding guys..don't give up