流程图:          c语言作业——闰年的判断

 

 

 

                                                                                       c语言代码:

#include <stdio.h>

int main()
{
  int year = 2000;
  while (year <= 2500)
  {
    if (year % 100 != 0 && year % 4 == 0 || year % 400 == 0)
    {
      printf("YES");
    }
    else
    {
      printf("NO");
    }
    year++;
  }
}

  return 0;
}

 

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-08-29
  • 2021-11-28
  • 2021-11-28
  • 2021-12-16
猜你喜欢
  • 2021-04-03
  • 2022-12-23
  • 2021-11-28
  • 2021-09-13
  • 2021-10-25
  • 2022-12-23
  • 2021-08-22
相关资源
相似解决方案