Assignment # 1: Analyze (I.e., Compute) The Running Time T (N) of The Following Nested Loops
Assignment # 1: Analyze (I.e., Compute) The Running Time T (N) of The Following Nested Loops
Assignment # 1
(Due date: 28.11.2016)
Analyze (i.e., compute) the running time T(n) of the following nested loops:
for i = 1 to n {
...
for j = 1 to 2*i {
...
k = j;
while (k >= 0) {
...
k = k - 1;
}
}
}
Additionally, please also write the combined Big-O of the above code.