a = [(q + w + e + r + t + y + u + i) for q in z for w in z for e in z for r in z for t in z for y in z for u in z for i in z]
import chardet
def detect_encoding(file_path):
with open(file_path, 'rb') as file:
raw_data = file.read()
result = chardet.detect(raw_data)
encoding = result['encoding']
return encoding
file_path = 'file.txt'
encoding = detect_encoding(file_path)
with open(file_path, 'r', encoding=encoding) as file:
content = file.read()
print(content)
import telebot
many = 0
def plus(message):
global many
if message.lower():
many += 1
print(f"Привет у тебя на балансе: {many}")
plus("message")
c:\>python tlb.py
Привет у тебя на балансе: 1