I'm trying to practice algorithm complexities, How do I do this?! I don't understand the problem or what calculations I have to do to get it... ANY help would be wonderful!
int N = 50 ;
int sum = 0 ;
for (int n = N ; n > 0 ; n/=2 ) {
for (int i = 0 ; i < n ; i++) {
sum++ ;
}
}