Determine the asymptotic time complexity for each of the following C++ code fragments.
Example 1.
Example 2.
Example 3.
Example 4.
Express the answer using "Big Oh" notation, as a function of n.