Question: Write a function in C to tokenize a string. The function should print each word on a new line without spaces. For example, if we

Write a function in C to tokenize a string. The function should print each word on a new line without spaces. For example, if we input "Hello, My _____ name is ____ Bob", (assume the underlines are whitespace. Chegg doesn't me allow type empty spaces for whatever reason) the output should be:

Hello,

My

name

is

Bob

Notice how all spaces are removed and each word is on a new line.

strtok is not allowed.

The signature of the function should be void printTokenizedStrings(char *inputString).

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!