get Random Number Between using Actionscipt AS3
The below code shows how to use the class
import druva.NumberUtil; trace(NumberUtil.getRand(5, 10));
This is the actual class for validation
package druva{
import flash.display.Sprite;
public class NumberUtil extends Sprite {
public function NumberUtil() {
}
public static function getRand(min:Number, max:Number):Number {
return Math.floor(Math.random()*(max+1-min))+min;
}
}
}