Had my phone interview recently. I was asked an LC hard problem similar to : 282. Expression Add Operators : https://leetcode.com/problems/expression-add-operators/
Two differences from the LC question :
My approach was to add valid numbers to a list like : 4,5,6 , 45, 56, 456 and via recursive backtarcking see if the combinations equal up to the given target. If they sum up to the target I would add it to the result list. But now after seeing the solution I know that it wouldn't lead to the correct solution.
I have no idea if it's possible for anyone to come up a solution in the 45 min interview of which abput 5-8 mins are used up for introductions.
Losing confidence :( I don't think I would have solved this even after 2 or 3 more months of preparation if I'm seeing this for the first time.
Please comment if any of you would be able to do it.
Loaction : google usa