CSC300: 5D Cube [13/19] Previous pageContentsNext page

01
02
03
04
05
06
07
08
09
10
11
    for (long i = 1; i <= N; i = i+1) {
      for (long j = 1; j <= N; j = j+1) {
        for (long k = 1; k <= N; k = k+1) {
          for (long l = 1; l <= N; l = l+1) {
            for (long m = 1; m <= N; m = m+1) {
              result = result+1;
            }
          }
        }
      }
    }

Output





Elapsed count f(            8):           32,768:     32.000 [     0.000 :        NaN]
Elapsed count f(           16):        1,048,576:     32.000 [     0.000 :        NaN]
Elapsed count f(           32):       33,554,432:     32.000 [     0.014 :   Infinity]
Elapsed count f(           64):    1,073,741,824:     32.000 [     0.620 :     44.286]
Elapsed count f(          128):   34,359,738,368:     32.000 [    17.720 :     28.581]
Elapsed count f(          256) aborted execution after a minute or so
Elapsed count f(          512) aborted execution after a minute or so
Elapsed count f(        1,024) aborted execution after a minute or so
Elapsed count f(        2,048) aborted execution after a minute or so
Elapsed count f(        4,096) aborted execution after a minute or so
Elapsed count f(        8,192) aborted execution after a minute or so
Elapsed count f(       16,384) aborted execution after a minute or so
Elapsed count f(       32,768) aborted execution after a minute or so
Elapsed count f(       65,536) aborted execution after a minute or so
Elapsed count f(      131,072) aborted execution after a minute or so
Elapsed count f(      262,144) aborted execution after a minute or so
Elapsed count f(      524,288) aborted execution after a minute or so
Elapsed count f(    1,048,576) aborted execution after a minute or so
Elapsed count f(    2,097,152) aborted execution after a minute or so
Elapsed count f(    4,194,304) aborted execution after a minute or so
Elapsed count f(    8,388,608) aborted execution after a minute or so
Elapsed count f(   16,777,216) aborted execution after a minute or so
Elapsed count f(   33,554,432) aborted execution after a minute or so
Elapsed count f(   67,108,864) aborted execution after a minute or so
Elapsed count f(  134,217,728) aborted execution after a minute or so
Elapsed count f(  268,435,456) aborted execution after a minute or so
Elapsed count f(  536,870,912) aborted execution after a minute or so
Elapsed count f(1,073,741,824) aborted execution after a minute or so
Elapsed count f(2,147,483,648) aborted execution after a minute or so

This is quintic: ~ N^5

Previous pageContentsNext page