Exemple #1
0
        private static void Main(string[] args)
        {
            FactService factService = new FactService(new CNRepository());

            string input = "";
            while (input != "n")
            {
                PrintFact(factService);
                input = System.Console.ReadLine();
            }

        }
Exemple #2
0
 private static async void PrintFact(FactService factService)
 {
     var fact = await factService.GetRandomFact();
     System.Console.WriteLine(fact.TheFact);
 }