When input is a string and not a single character

when input is a string and not a single character, shouldnt the program output the first letter of the string and then move to cin which should ask for a new input and the remaining string gets discarded?

Hi @tusharnitharwal
Input that is written on terminal is a string but we have defined in our code ch as a char which takes only one character at a time from the input string. Input string on pressing enter is stored in an input buffer and from there one by one character is taking as input and stored in ch till we encounter ‘.’ .