Calculate amount of iterations
How can I calculate how many iterations will be done by these loops for
any given N (>= 1)
for (1 <= k <= N)
for (0 <= i < 6)
for (0 <= j < k)
...
I'm especially having problems of how to deal with the innermost loop,
because it depends on the value of the outermost loop. Basicall, it will
be something like N * 6 * ???, but I can't figure out what ??? should be
No comments:
Post a Comment