Question: C++ Write a function Split(...) that is given a string, a separator character, an array to fill and the max number of elements in the

C++ Write a function Split(...) that is given a string, a separator character, an array to fill and the max number of elements in the array as parameters and returns an integer result. The function will separate each substring of the given string between separator characters and place it in the array. The function returns the number of substrings extracted. For example: string words[10]; Split("cow/chicken/fish", '/', words[], size ); would return the count of 3 and fill the array with "cow", "chicken", "fish". **Int main() calls out to the function Split. Please include the int main()

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!