提供一种算法: #define max(a, b) ((((a)-(b)) + fabs(a-b))?(a):(b)) 转载于:https://www.cnblogs.com/mclown/p/algorithm01.html