python C:\Users\Администратор.WIN-5BM7OVOFTOS\Desktop\CRM-Avi\main_operation.py
import turtle
def draw_n(n, length, x = 0,y = 0):
turtle.penup()
turtle.setpos(x,y)
turtle.pendown()
deg = 180 - 180*(n-2)/n
print(deg)
for i in range(n):
turtle.left(deg)
turtle.forward(length)
win = turtle.Screen()
table = turtle.Turtle()
win.setup(600,600)
table.pencolor("black")
draw_n(8,100,100,100)
MyFunc =lambda x, y : eval(input()) ##Вводишь выражение где фигурируют x,y
MyFunc(1,2) ## Вызов функции, x = 1 y = 2
import telebot
from telebot import types
API_TOKEN = '<api_token>'
bot = telebot.TeleBot(API_TOKEN)
@bot.message_handler(commands=['help', 'start'])
def send_welcome(message):
markup = types.ReplyKeyboardMarkup(one_time_keyboard=True)
markup.add('1', '2') #Имена кнопок
msg = bot.reply_to(message, 'Test text', reply_markup=markup)
bot.register_next_step_handler(msg, process_step)
def process_step(message):
chat_id = message.chat.id
if message.text=='1':
func1()
else:
func2()
return HMAC(key, msg, digestmod)
return HMAC(key.encode(), msg.encode(), digestmod)