static void Main(string[] args) { try { IRepo repo = new RepoFile(); Console.WriteLine("Write some words which should be stored"); string text = Console.ReadLine(); repo.Save(text); } catch (Exception e) { Console.WriteLine("Exception occurs: " + e.Message); } }