Accenture interview question

Coding on Pointers