Microsoft Interview Question

Standard Word break DP, problem