Posted to tcl by evilotto at Thu Mar 02 18:52:30 GMT 2017view raw

  1. % set a 1
  2. 1
  3. % time {set a [expr $a + 1]} 1000000
  4. 2.834298 microseconds per iteration
  5. % set a 1
  6. 1
  7. % time {set a [expr {$a + 1}]} 1000000
  8. 0.422323 microseconds per iteration
  9. %
  10.