ByteDance interview question

Chinese words and dynamic programming