Que bueno que me entendiste.... aunque ahora paso a otro problemilla

.... quiero que en vez de dejar definido el string, este se pueda capturar e imprimir de la misma forma en la que lo hace tu ejemplo...
tengo este codigo...

pero solo me imprime todo lo que este antes del espacio... lo demas es como si lo ignorara...
codigo:
#include <cstdlib>
#include <iostream>
#include <stdio.h>
#include <string>
using namespace std;
int main(int argc, char *argv[])
{
char str[20];
cout<<"ingrese nombre\n";
cin>>str;
char * pch;
pch = strtok (str," ");
while (pch != NULL)
{
printf ("%s\n",pch);
pch = strtok (NULL, " ");
}
system("PAUSE>nul");
return 0;
}