subject
Computers and Technology, 13.11.2020 01:00 doversu

PLEASE HELP asap 60 POINTS needs to be in Java

A programmer has written a method called replaceLetter that counts the amount of times a letter is present in a word. Your job is to modify this existing method to fulfill a new purpose.

Rather than count the instances of a letter in a String, write a program that replaces all instance of one letter with another. You should directly modify replaceLetter to get this program to work. In the starter code, replaceLetter only has two parameter values. Your new version should have a third parameter to indicate which String value is replacing the existing letter.

For example,

replaceLetter("hello", "l", "y")
returns

"heyyo"
Sample output:

Enter your word:
hello

Enter the letter you want to replace:
l

Enter the replacing letter:
x
hexxo
Hint: The letters will be assigned from the user as String values. Make sure to use String methods to compare them!

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 05:00
Acompany is inviting design for its new corporate logo from its users. this is an example of ? a. crowdfunding b. crowdvoting c. crowdsourced design d. crowdtracking
Answers: 3
question
Computers and Technology, 23.06.2019 11:30
In cell h5 enter a formula that will calculate the percentage of attendees that went to the altamonte springs job fair in 2018.
Answers: 1
question
Computers and Technology, 23.06.2019 15:30
Write a program in plp assembly that counts up by one starting from zero (or one) inside a loop and writes this value to the leds every time the value is increased. the memory address of the leds is 0xf0200000. the table below shows the meaning and an example usage of the instructions covered in the video, plp instructions for project 1. instruction example usage meaning load immediate li $t0, 8 register $t0 is set to the value, 8. store word sw $t2, 0($t1) the value in register $t1 is used as the memory address. the value in register $t2 is copied into this memory address. add addiu $t4, $t3, 29 register $t4 is assigned the sum of 29 and the value in register $t3. jump j your_label_name the program jumps to the line following the label, "your_label_name: ". label your label name: defines a label called "your_label_name: " that can be jumped to
Answers: 2
question
Computers and Technology, 23.06.2019 18:00
Which finger presses the h key on the keyboard? index finger on the left hand pinky finger on the right hand index finger on the right hand thumb on the left hand
Answers: 1
You know the right answer?
PLEASE HELP asap 60 POINTS needs to be in Java

A programmer has written a method called...
Questions
question
Mathematics, 05.02.2022 14:00
question
Mathematics, 05.02.2022 14:00
question
English, 05.02.2022 14:00
Questions on the website: 13722361