equal
deleted
inserted
replaced
48 for (j <- 1 to i) code |
48 for (j <- 1 to i) code |
49 val end = System.nanoTime() |
49 val end = System.nanoTime() |
50 (end - start)/(i * 1.0e9) |
50 (end - start)/(i * 1.0e9) |
51 } |
51 } |
52 |
52 |
53 for (i <- 1 to 100) { |
53 //for (i <- 1 to 100) { |
54 println(i + ": " + "%.5f".format(time_needed(1, matches(EVIL(i), "a" * i)))) |
54 // println(i + ": " + "%.5f".format(time_needed(1, matches(EVIL(i), "a" * i)))) |
55 } |
55 //} |
56 |
56 |
57 //a bit bolder test |
57 //a bit bolder test |
58 for (i <- 1 to 1000 by 50) { |
58 for (i <- 1 to 1000 by 50) { |
59 println(i + " " + "%.5f".format(time_needed(1, matches(EVIL(i), "a" * i)))) |
59 println(i + " " + "%.5f".format(time_needed(1, matches(EVIL(i), "a" * i)))) |
60 } |
60 } |