testing new function inside random