Question: Fill in the empty highlighted spots in order to conplete a code to write a program in Java that takes in as input a string

Fill in the empty highlighted spots in order to conplete a code to write a program in Java that takes in as input a string message and an integer. The program will then scramble the message by converting each character of the message to its numeric code, adding the specified integer to this code, then converting the resulting number back to a character. To do this, you must create a class that handles a string and the encoding integer as inputs.Required Class Variables: You need a string to hold the message, and a variable of type into to hold the value to encode the message with.Required Member Methods:getMessage: reads in and stores the message stringgetCode: reads in and stores the encoding valueencrypt: takes in a single letter as input and returns a result of type charencryptAll: uses a loop to go through the string and encrypt the contents using encrypt functionprintOut: Prints out the contents of the converted array messageVFor example, on a computer the following ASCIl text:THE REDCOATS ARE COMING!Followed by an integer of 5 would produce the following:YMJ WIIHTFYX FWJ HTRNSL&
Fill in the empty highlighted spots in order to

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 Programming Questions!