private static void GetValuesFromPeriod(int period, ShowPeriodWindow window, bool isPeriod)
 {
     if (isPeriod)
     {
         window.PeriodCountTextBlock.Text = period.ToString();
     }
     else
     {
         window.APeriodCountTextBlock.Text = period.ToString();
     }
 }
        private static void ShowResult(Generator generator)
        {
            var window = new ShowPeriodWindow();

            var period   = generator.Period;
            var aperiods = generator.APeriod;

            GetValuesFromPeriod(period, window, true);

            foreach (var aperiod in aperiods)
            {
                GetValuesFromPeriod(aperiod, window, false);
            }

            window.Show();
        }