Help...
I got this code segment from Data Structure Book (Recursive Chapter).
I need some one to describe to me the Flow of the function specially ( return half*half ) part.Where is the value of the return
Thanks a lot.Code:#include <iostream.h> int power(int X,int N) { if(N == 0) return 1; else { int half = power(X,N/2); if(N%2 == 0)//even return half * half ; else //odd return X * half * half ; } } int main() { int p = power(3,4); return 0; }