progs/re3.scala
changeset 121 43c116860e47
parent 119 a6684e8961d0
child 258 1e4da6d2490c
equal deleted inserted replaced
120:3e71efb25ce9 121:43c116860e47
       
     1 import scala.language.implicitConversions    
     1     
     2     
     2 abstract class Rexp {
     3 abstract class Rexp {
     3   def simp : Rexp = this
     4   def simp : Rexp = this
     4 }
     5 }
     5 
     6 
    96   val end = System.nanoTime()
    97   val end = System.nanoTime()
    97   (end - start)/(i * 1.0e9)
    98   (end - start)/(i * 1.0e9)
    98 }
    99 }
    99 
   100 
   100 
   101 
   101 for (i <- 1 to 11001 by 500) {
   102 for (i <- 1 to 12001 by 500) {
   102   println(i + " " + "%.5f".format(time_needed(1, matcher(EVIL(i), "a" * i))))
   103   println(i + " " + "%.5f".format(time_needed(1, matcher(EVIL(i), "a" * i))))
   103 }
   104 }
   104 
   105 
   105 
   106