MTAP Technologies interview question

Java coding interview question on Array and String