Computer Science Canada

java programming help!

Author:  miriamyeungovrsea [ Wed Dec 12, 2012 6:49 pm ]
Post subject:  java programming help!

May you guys help me with this problem. Can you guys use not a very complex style of writing this program? Thanks.

Build a RemoveString class that prompts the user for a sentence and a word to remove.

(a) Write a method, removeString( sentence, word), that removes the first occurrence of the given string from
the sentence.

(b) Write a method, removeAll( sentence, word), that removes all occurrences of word from the sentence. This
method should call the method you developed in part (a) repeatedly until all occurrences of word are removed.

Author:  DemonWasp [ Wed Dec 12, 2012 7:24 pm ]
Post subject:  RE:java programming help!

This sounds like a homework question. What have you tried doing to solve this problem?

If you run into trouble, we can help you, but we can't answer homework problems for you.

Author:  miriamyeungovrsea [ Wed Dec 12, 2012 7:25 pm ]
Post subject:  RE:java programming help!

im a beginner, so i don't even know how to do this.

Author:  Insectoid [ Wed Dec 12, 2012 7:58 pm ]
Post subject:  RE:java programming help!

(a) You're probably going to need to use a string tokenizer. Sound familiar? I'd bet your teacher explained it in class.

(b) should be trivial once you've finished (a).


: