Hello. The cycle should run about a million times. At the same time you need to keep within the minimum time. I know for example in php certain cycles (especially for arrays) work faster than others (for example, foreach). Is there anything similar in javascript?
Supplemented.
Here is the cycle that should be executed a million times =):
for (i = 0; i < n; i++) { t = t + '<tr>'; for (j = 0; j < n; j++) { t = t + '<td></td>'; } t = t + '</td>'; }