public static void Main()
Console.WriteLine("Press E to ENCRYPT or press D to DECRYPT");
string choice = Console.ReadLine();
if (choice == "E" || choice == "e")
Console.WriteLine("Enter the text you would like to encrypt **IN ALL CAPS");
string text1 = Console.ReadLine();
Console.WriteLine("Message: " + Encrypt(text1));
if (choice == "D" || choice == "d")
Console.WriteLine("Enter the text you would like the decrypt **IN ALL CAPS");
string text2 = Console.ReadLine();
Console.WriteLine("Message: " + Decrypt(text2));
Console.WriteLine("Would you like to restart? y/n?");
string restart = Console.ReadLine();
if (restart == "y" || restart == "Y")
if (restart == "n" || restart == "N")
Console.WriteLine("Okay have a good day!");
private static string Encrypt(string x)
char[] temp = x.ToCharArray();
for (int i = 0; i < x.Length; i++)
string cipher = new string (temp);
private static string Decrypt(string x)
char[] temp = x.ToCharArray();
for (int i = 0; i < x.Length; i++)
string cipher = new string (temp);