string text = (year % 4 == 0 && year % 100 != 0 || year % 400 == 0) ? "闰年" : "平年";
string text=year/4>=1?"平年":"闰年";这样也可以
string text = year % 4 >= 0 ? "闰年" ? "平年";
就行了吧?是我想少了?
对的啊