import operator
action = {
"+": operator.add,
"-": operator.sub,
"/": operator.truediv,
"*": operator.mul,
"**": operator.pow
}
# .....
b = float(input())
a = float(input())
x = input()
act= action.get(x, None)
if act:
try:
answer = act(a, b)
except ZeroDivisionError as e:
print(u"Деление на 0!")
else:
print(answer)
for i , name in enumerate(data):
print("".join([name, str(i), '.csv'])
# передача параметра (как вариант)
def mess_convert(el):
SymTo2Bin = ConvertFromDec(el, 10, 2)
RSLength = len(SymTo2Bin[2:])
TMessage = ''
while RSLength < 9:
TMessage += "0"
RSLength += 1
TMessage += SymTo2Bin[2:]
MMessage.append([TMessage[d:d + 3] for d in range(0, len(TMessage), 3)])
return MMessage
def mess():
for sym in Message:
mess_convert(ord(sym)
mess_convert(len(Message))