Optum interview question

How i answered the coding challenge