0% found this document useful (0 votes)
58 views1 page

Code Python to Generat Code Fibre Orange

Uploaded by

achra56545f
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
58 views1 page

Code Python to Generat Code Fibre Orange

Uploaded by

achra56545f
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1

import random

import string
import os

def generate_wordlist(length, num_codes):


# Define the character pool: uppercase letters and digits
characters = string.ascii_uppercase + "0123456789"

# Generate the codes


wordlist = []
for _ in range(num_codes):
code = ''.join(random.choices(characters, k=length))
wordlist.append(code)

return wordlist

# Configuration
num_codes = 90000000 # Number of codes to generate
length = 18 # Length of each code (18 characters)

# Generate the codes


wordlist = generate_wordlist(length, num_codes)

# Get the desktop path


desktop_path = os.path.join(os.path.expanduser("~"), "Desktop", "wordlist.txt")

# Save the codes to a text file on the desktop


with open(desktop_path, "w") as file:
file.write("\n".join(wordlist))

print(f"Generated {num_codes} codes, each {length} characters long, and saved to


'{desktop_path}'.")

You might also like