A few minors for now: 1. Your `Cell` struct should be immutable - you can achieve that by making all the fields `readonly`. 1. In `Cell` `character` should be `PascalCase`. 1. You repeat the code for trimming and replacing characters for they key and plain text. This should be moved into a method. 1. There is some convoluted code which iterates of the `keyWord` and adds stuff to a `keyString`. If I read it correctly then what this is doing is: Build a list of all unique characters and remove those from the alphabet. LINQ is perfect for doing that in a concise way: var uniqueKeyChars = keyWord.Distinct().ToList(); alphabet = alphabet.Except(uniqueKeyChars).ToArray();