3 ms·
UUIDs of all formats are universally unique, for all practical purposes. Consider UUID4, the one with 122 random bits. The birthday paradox says that you would
by rspeer 10y ago
UUIDs of all formats are universally unique, for all practical purposes.
Consider UUID4, the one with 122 random bits. The birthday paradox says that you would need about 2^61 UUIDs before you expect even one duplicate. If this concerns you, you might not recognize how big 2^61 is.
(edited because I was originally talking about 2^64, but there are 6 non-random bits in UUID4)
- dbenhur 10y agoWhat does "expect even one" mean? This is a probability equations, so what p does expect correspond to? Let's make this real concrete, with 122 random bits, you can issue a million UUIDv4s every second for the next 100 years and still have a less than one in a million chance that you issued a duplicate. https://lazycackle.com/Probability_of_repeated_event_online_calculator__birthday_problem_.html https://lazycackle.com/Probability_of_repeated_event_online_... n = 5316911983139663491615228241121378304 (2122) p = 0.000001 => m = 3260955271619137 3260955271619137/(100000086400365) => 103