\documentclass[12pt,ifthen]{article} \usepackage{url} \usepackage{comment} \usepackage{hyperref} \usepackage{xcolor} \newif{\ifshowsoln} %\showsolntrue \newcommand{\und}{\_\_\_\_\_\_\_\_\_} \newcommand{\Z}{\mathbb{Z}} \newcommand{\tab}{\phantom{\qquad}} \usepackage{amsmath} \usepackage{amssymb} % for \nmid \begin{document} \centerline{\textbf{Honors HW 9. Morally Due April 19} } This is a programming problem. Send your code to Emily by email. Send the actual .java/.py/ect file. You need to use your .umd email address or it will not send. In your pdf, you must have the output your code provides. You can screenshot this or type it in. Hint: Use Python. In this problem we will look at the SHIFT cipher when you include not just letters, but also digits. So our alphabet will be $\{a,b,c,\ldots,z,0,1,\ldots,9\}$. \begin{enumerate} \item Write a program that will take a text (which may have numbers in it), and a number $0\le s\le 35$, and output the result of shifting the ext by $s$. Do this by: \begin{enumerate} \item Writing a method that takes a text and (1) eliminate all non-alphanumeric symbols and whitespace, (2) replace $a$ and $A$ with 1, $\ldots$, replace $z$ and $Z$ with 26, replace 0 with 27, replace 1 with 28, $\ldots$, replace 9 with 36. \item Writing a method that will, given a text of numbers in $\{1,\ldots,36\}$, and a number $0\le s\le 35$, output text shifted by $s$. \item Writing a method that will, given a text of numbers in $\{1,\ldots,36\}$, use the decoding $0$ goes to $a$, 1 goes to $b$, 25 goes to $z$, 26 goes to 0, $\ldots$, 35 goes to 9 to produce a text over $\{a,\ldots,z,0,\ldots,9\}$. \end{enumerate} \item Run the program on the following text: \color{blue} \href{https://www.popularmechanics.com/science/math/a36014795/mathematicians-discover-new-kind-of-prime-number/}{``Mathematicians Discovered a New Kind of Prime Number"}\color{black} with $s=1$. This is hyperlinked. Click it to find the text. Use only the articles text not the adds around it. Print this output and put it in the pdf for your submission. \item Take the output $T$. Run the program on it with $s=25$. You should get back the original text. Print this output and put it in the pdf for your submission. \end{enumerate} \end{document}