added NSArray methods to work with randoms