01Count steps, not seconds
Seconds depend on your laptop, your language and your compiler. What does not change is how many basic steps the algorithm performs: a comparison, an addition, an array read.
So we describe the cost as a function of the input size n. A single loop over an array touches each element once: about n steps. A loop inside a loop touches every pair: about n × n steps.
For n = 6 that is 6 versus 36. For n = 100 000 it is a hundred thousand versus ten billion. The first finishes instantly; the second takes many seconds. The shape of the code tells you the shape of the cost.