UUID
, and when might you use it?Suggested approach: UUID stands for "universally unique identifier", which is a long string of hexadecimal numbers stored in a single type.
UUIDs are helpful for ensuring some value is guaranteed to be unique, for example you might need a unique filename when saving something.
For bonus points, perhaps explain why we call them universally unique – if you created 100 trillion UUIDs there's a one in a billion chance of generating a duplicate.
Estimated difficulty: Intermediate
See the full list of iOS interview questions
Link copied to your pasteboard.