I wanted to store string values at a particular index of the character array using a while loop.
Condition for while loop termination : \'q\' should be pressed to stop t