Added more randomness and maxSize trait