add a random element in case of duplicate timestamps