Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create V4R2 #1

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Create V4R2 #1

wants to merge 1 commit into from

Conversation

wanglin7788
Copy link

import tqdm
from tonsdk.contract.wallet import Wallets, WalletVersionEnum

Function to create wallets and save to file

def generate_wallets(count):
output = ""
for i in tqdm.tqdm(range(count), desc="Generating wallets"):
mnemonics, pub_k, priv_k, wallet = Wallets.create(WalletVersionEnum.v4r2, workchain=0)
wallet_address = wallet.address.to_string(True, True, False)

    output += "\n\n" + wallet_address + "\n" + ' '.join(mnemonics) + "\n"

with open("wallets.txt", "a") as f:
    f.write(output)

Main script

if name == "main":
print("""

Wang Lin

                   by Aero25x                                           
      
      """)
count = input("Enter the number of wallets to generate: ")
try:
    count = int(count)
    generate_wallets(count)
except ValueError:
    print("Please enter a valid number.")

mu crd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant