about | help | code help+videos | done | prefs |
Write a method that returns the string str, but with all occurrences of ltr removed from the string. You can only use the following string commands: .length, .substring, .charAt, .equals. Look at the test data for details. Keep in mind that this will be case sensitive, so only replace a letter if it matches the same case. Also, a "letter" can really be any symbol. retestQuiz05272014RemoveLetter("This is a test", "i") → "Ths s a test" retestQuiz05272014RemoveLetter("a man a plan a canal panama", "a") → " mn pln cnl pnm" retestQuiz05272014RemoveLetter("what are you doing?", "z") → "what are you doing?" ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 290
Copyright Nick Parlante 2017 - privacy