To extract the first letter of the second word of a string you have to find the second word in the string.:)
There are several methods to do the task. For example you can use member functions of the class string such as find() to find the second word. Or you can use istringstream to do the same.