floatTiming.frink

View or download floatTiming.frink in plain text format


runs = million
c = 3.
for precision = 20 to 6 step -1
{
   setPrecision[precision]
   a = 1/c
   b = 2/c

   println["\nPrecision: $precision"]
   for r = 1 to 10
   {
      start = now[]
      for i = 1 to runs
         c = a / b
      end = now[]

      println["Time was: " + (end-start -> "ms")]
   }
}


View or download floatTiming.frink in plain text format


This is a program written in the programming language Frink.
For more information, view the Frink Documentation or see More Sample Frink Programs.

Alan Eliasen was born 17684 days, 8 hours, 56 minutes ago.