Python/Lab_4/tst.py

7 lines
231 B
Python
Raw Normal View History

2024-03-09 17:38:18 +02:00
from random import sample
symbols = bytearray(input("Your sequence: ").replace(" ", ""), "utf_8")
print(str(bytearray(sample(symbols, 3)), "utf_8"))
#print(f"Your word: {bytearray(sample(symbols, 3)).decode(encoding='utf_8')}.")