/* 请写成下列宏定义 1.min(a,b) 求a,b的最小值 2.islower(c), 判断c是否为小写字母 3.isleap(year), 判断year是否为闰年 4.circumference(r), 计算半径为r的圆周长 */ #include <stdio.h> #define min(a,b) ((a)>(b)?(a):(b)) #define isLower(c) (((c) < 'z' && (c) > 'a')? "True": "False") #define isLeap(year) (((((year)%4==0&&(year)%100!=0)||(year)%400==0)? "True": "False")) #define PI 3.14159265 #define circumference(r) (2*PI*(r)) int main() { printf("%s ", isLeap(2004)); printf("%s ", isLeap(100)); printf("%f ", circumference(4)); printf("%c ", min('z', 'A')); printf("%d ", min(100, 67)); printf("%s ", isLower('A')); return 0; }