Fixed return type of findRandomWithCount