UnitedHealth Group interview question

Dynamic algorithm design question