mercredi 24 juin 2020

How to generate unique pairs of numbers on python

So I’m working on a chat application right now.. let’s say we have User1, User2, User3, ...UserN. I want to generate a unique port number for each pair. Like User1 and User2 will have 5000, User1 and User3 will have 5070, User2 and User3 will have 5500, etc etc.. basically every User should have a different port number for other users.. but both of the Users should have the same one for each of them.




Aucun commentaire:

Enregistrer un commentaire