Capgemini Engineering interview question

Basic questions of array and string