Answer in one line: ''.join(random.choice(string.ascii_uppercase + string.digits) for _ in range(N)). or even shorter starting with Python ... ... <看更多>
Generates random numbers with help of random-number generator rand::Rng ... Randomly generates a string of given length ASCII characters in the range A-Z, ... ... <看更多>