GATEverse
← GATE CSE 2014 Set 3

Q39

NAT2 marks

Suppose we have a balanced binary search tree TT holding nn numbers. We are given two numbers LL and HH and wish to sum up all the numbers in TT that lie between LL and HH. Suppose there are mm such numbers in TT. If the tightest upper bound on the time to compute the sum is O(nalog⁡bn+mclog⁡dn)O(n^a\log^bn+m^c\log^dn), the value of a+10b+100c+1000da+10b+100c+1000d is ______.

Sign in to save attempts.

Loading…