标签:== stdio.h void 最小值 turn style print 语言 span
#include <stdio.h> #define N 10 #define MIN(X,Y) ((X<Y)?(X):(Y)) int f(int arr[],int len,int n) { if(n == len-1) return arr[n]; int min = f(arr,len,n+1); return MIN(min,arr[n]); } int main (void) { int arr[N] = {2,4,1,3,5,6,7,8,-11}; int min = f(arr,N,0); printf("%d ",min); return 0; }
标签:== stdio.h void 最小值 turn style print 语言 span
原文地址:https://www.cnblogs.com/sea-stream/p/10009850.html