public void writeLines(Alphabetizer alphabetizer) { var lines = alphabetizer.getLines(); using (System.IO.StreamWriter file = new System.IO.StreamWriter(@FileName)) { foreach (string line in lines) { file.WriteLine(line); } } }
static void Main(string[] args) { Input input = new Input("Input.txt"); Characters characters = new Characters(input.readLines()); CircularShifter circularShifter = new CircularShifter(characters); Alphabetizer alphabetizer = new Alphabetizer(circularShifter); Output output = new Output("Output.txt"); output.writeLines(alphabetizer); System.Console.ReadKey(); }