I'm hoping to use a four character join code so people can join a game. I was thinking of making random codes, which would be about 1.4 million different possible codes. I like the idea but I don't want to repeat one by accident.
I'm using Firebase for my database, so I was thinking of just storing all the combinations in a document and grabbing the next in line.
These both sound not-so-great. It seems like there's a better way. Thoughts?