make randomElements ~12% faster