Computer Science, Python, Big O Notation, Time Complexity, Algorithms.
runs even longer, but the degree of the power won’t change — O(n²+n). According to the drop non-dominants concept, we don’t take into account the smaller degree and remain just O(n²). def o_squeared(n): for i in range(n): for j in range(n): print(i, j) for k in range(n): print(k) O(log n) —