Given a full name in a string, how do I output the first, last, and middle names without using an array?

Hi,

I'm taking an Intro to Programming course, even though I already have some C-style programming experience. One of our homework assignments is to take a full name in the form of a string (the book gives "John Jacob Schmidt" as an example) and output:

First name: John
Middle name: Jacob
Last name: Schmidt

Normally, I'd go find a way to separate the given string by the substring " ", but I want to go more "by the book". In the chapter, we talk about string manipulation, and finding a substring given a location and length.

One more thing: I am not allowed to use anyone else's code without proper citation and my professor's permission.
Ok, so thanks to http://stackoverflow.com/questions/1351871/simple-c-code-whats-wrong-here/9503270#9503270, I now see that the answer has to do with the find() function on string.
I would like to learn about this.
Mooman, kindly elaborate on the find () and delimiters please
Topic archived. No new replies allowed.