next up previous
Next: Check balance and nesting Up: Assignment 5: Stacks Previous: Generic lists

Implement split

  1. Write a List method called split that takes a String, breaks it up into words (using spaces as delimiters), and returns a list of Strings, with one word per list node.

    Your implementation should be efficient, meaning that it takes time proportional to the number of words in the string.



Allen Downey
Tue Oct 10 15:33:10 EDT 2000