added value for RAND_MAX even though it should be built in