//判断1000年---2000年之间的闰年
#include <stdio.h>
int main()
{
int i;
for( i = 1000; i <= 2000; i++ )
{
if( ( i % 4 == 0 && i % 100 != 0 ) || i % 400 == 0)
printf("%d\t",i);
}
return 0;
}
</pre><pre code_snippet_id="624289" snippet_file_name="blog_20150320_1_7940354" name="code" class="cpp">
<img src="https://img-blog.csdn.net/20150323195622673?watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvenlxMTMyMjc4MjUwMTl6eXE=/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/Center" alt="" />