Pitfall in producing random numbers