要求按标准日历方式输出指定年月的日历样式

1  2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31

 1综合练习:简单日历            System.DateTime dt = System.DateTime.Now;
 2综合练习:简单日历            dt = dt.AddDays(-(dt.Day - 1));
 3综合练习:简单日历            int thisMonth = dt.Month;
 4综合练习:简单日历            System.Console.WriteLine(dt.ToLongDateString());
 5综合练习:简单日历            char[] weekChar = "日一二三四五六".ToCharArray();
 6综合练习:简单日历            for (int i = 0; i <= weekChar.Length - 1; i++)
 7            System.Console.WriteLine();



 

 

 

 

相关文章:

  • 2021-06-08
  • 2021-11-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-16
  • 2021-09-15
猜你喜欢
  • 2022-12-23
  • 2021-12-04
  • 2021-08-28
  • 2021-12-23
相关资源
相似解决方案