Problems
Write a program that receives a string, including spaces, and separates it as described below, printing each part with a number. The length of the string does not exceed 100 characters.
When inputting the sentence, use the
fgets()function instead ofgets(). Use C++14.
Example
My name is Kimchulsoo
1. My
2. name
3. is
4. Kimchulsoo
Source
자기주도C언어프로그래밍