コード例 #1
0
ファイル: Program.cs プロジェクト: JustinKasbrick/wstn49stats
        static void DailyGetLastRoundStats()
        {
            IFileReader fileReader = new FileReader();
            var         lines      = fileReader.ReadNLinesFromFile(10, "../../../Data/dailydata.txt");

            IRoundParser roundParser = new DailyRoundParser();

            var(numbers, draws) = roundParser.GetNDraws(10, 0, lines, new List <int>());

            var allPatterns = new List <string>();

            IRoundAnalyser roundAnalyser = new DailyRoundAnalyser();
            var            stats         = roundAnalyser.GetStatsForRound(draws, numbers);
            var            first7Draws   = roundAnalyser.GetStatsForFirst7Draws(draws, numbers);

            allPatterns.Add(stats.Template);

            IPrinter printer = new Printer(true);

            printer.PrintRound(draws, numbers);
            printer.PrintRoundStats(stats);


            Console.WriteLine();
            printer.PrintRoundStats(first7Draws);
        }
コード例 #2
0
ファイル: Program.cs プロジェクト: JustinKasbrick/wstn49stats
        static void DailyGetLast6Rounds()
        {
            IFileReader fileReader = new FileReader();
            var         lines      = fileReader.ReadNLinesFromFile(9 + (10 * 5), "../../../Data/dailydata.txt");

            IRoundParser roundParser = new DailyRoundParser();

            var(numbers, draws) = roundParser.GetNDraws(9, 0, lines, new List <int>());

            IPrinter printer = new Printer(true);

            Console.WriteLine("??-??-??-??-??");
            printer.PrintRound(draws, numbers);
            Console.WriteLine();

            for (int i = 0; i < 5; i++)
            {
                for (int j = 0; j < 10; j++)
                {
                    (numbers, draws) = roundParser.GetNDraws(1, 7 + ((i * 8) + j), lines, numbers);
                    printer.PrintSubsiquentRound(draws, numbers);
                }

                Console.WriteLine();
            }

            Console.ReadLine();
        }