Saturday, December 27, 2008

Random Integer

Our PHP programmer friends have a function called randInt() which returns a random integer between two specified integers. It's time to level the playing field.


ASP

  1. function randInt(min, max)
  2.     Randomize
  3.     randInt = Int((max - min + 1) * Rnd + min)
  4. end function

View ASP implementation on Snipplr

No comments: