Doubt doubt doubt

What does cin.get() do???
Also please explain the for loop which prateek bhaiya uses after cin.get(). How it is working ???

hello @parth_tyagi

it reads one character at a time.

here in this code we are using this to read \n.

that loop is running n times and in each ieration it reads one line and stores it in a[i]