Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

This question was also discussed in class. Review the slides (see above) prior t

ID: 3832832 • Letter: T

Question

This question was also discussed in class. Review the slides (see above) prior to working on this problem. The problem is essentially an encoding/decoding problem losely based on the German Enigma machine used during WWII. This is the code that Allan Turing and his colleagues broke. The movie "The Imitation Game" gives a fairly good historical account of this enterprise. For this problem you pick a 3-letter English word and encode each letter in the 3-letter word randomly, using one of the 26 letters of the alphabet.All of the encoded 3 letters may be the same as the original. Use this MS-Word file for more detailed instructions FinalExamCodeProblem.docxPreview the documentView in a new window Requirement: 1. You pick the word you want to encode. Show the word in a small window labeled "original word" (this is not user input. it is only for showing the word you picked). 2. Make two more small windows. One where you show the encoded word and another where you show the decoded word so it can be compared to the original. 3. Have a simple GUI with an encode button to start the program and a decode button to decode 4. Print the the encoded word after the encode button is pushed and print the decoded word when the decode button is pushed and the program terminates.. 5. Write a timer that measures the number of milliseconds it took to decode. (you may use a window for that as well)

THIS IS THE CODETHAT I HAVE SO FAR! BUT I AM RECEIVING AN ERROR AT THE END OF THE CODE AT LINE :

array[i]=(""+Alphabet[i]+""+EncryptedWord[1]+""+EncryptedWord[2]);

HOW CAN I MAKE THIS CODE WORK?

Explanation / Answer

Please let me know in case of any issue.


array[i]=(""+Alphabet[i]+""+EncryptedWord[1]+""+EncryptedWord[2]);

There can be two possible reason for compile time error:

   array[i] is not type of String

OR i might be initialized before this line;
   All local variables must be initialized before use.

Also check whether Alphabet EncryptedWord and EncryptedWord arrays exist in scope of this line

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote