Question: Use Java, Do not import any packages (only java.lang.*), write public static String encrypt(String input) It encrypts the input string by applying the Atbash cipher
Use Java, Do not import any packages (only java.lang.*), write public static String encrypt(String input) It encrypts the input string by applying the Atbash cipher on letters (both uppercase and lowercase) and reversing the encrypted string, and then returns the reversed encrypted string.
Examples:
| Input | Output |
| abcdefg, hijklmn, OPQRST, UVWXYZ! | !ABCDEF ,GHIJKL ,mnopqrs ,tuvwxyz |
| ENCRYPT encrypt? | ?gkbixmv GKBIXMV |
| CsE BaSeMeNt >.< | <.> gMvNvHzY VhX |
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
