Infosys interview question

Coding questions on arrays and strings.