assign index numbers 1..N to each node
let X = 2^i + k*2^i
node X has (X +/- 2^(i-1)) as its children
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Algorithm Geeks" group.
To post to this group, send email to alg
>> as if it can be improved
how? by making it more readable or making it more concise? here is a
version that is a lil concise and a lot more readable:
enum comp { lesser, greater };
int greater_lesser(int a, int b, enum flag=greater){
if(flag==greater)
return a > b ? a : b;
else