CodingEasy
Shortest function length to generate wanted array
Filed under Morgan Stanley
The question
Given two arrays A and B and a target array 'wanted', along with 8 candidate functions of fixed lengths, determine the length of the shortest function that transforms A and B into the wanted array. If no function works, return -1.
No write-up yet. Related questions below have one.
Related Morgan Stanley questions
Collected from public candidate posts and coding forums. Updated Nov 2026.