using System.Collections.Generic;
using System.Globalization;
public partial class RKABRincianMonthYear
public int Year { get; set; }
public int Month { get; set; }
public static void Main()
Console.WriteLine("Hello World");
DateTime startdate = new DateTime(2022, 01, 10);
DateTime enddate = new DateTime(2022, 08, 10);
List<RKABRincianMonthYear> newListRKABRincianMonthYear = new List<RKABRincianMonthYear>();
while (startdate.Year*12+startdate.Month <= enddate.Year*12+enddate.Month)
var newRKABRincianMonthYear = new RKABRincianMonthYear();
newRKABRincianMonthYear.Month=startdate.Month;
newRKABRincianMonthYear.Year=startdate.Year;
newListRKABRincianMonthYear.Add(newRKABRincianMonthYear);
startdate = startdate.AddMonths(1);
foreach(var obj in newListRKABRincianMonthYear)
Console.WriteLine(obj.Month.ToString()+", "+obj.Year.ToString());