title: Problem with basic Maths in Python and discord.py
body: <p>I'm pretty new to programming and i wanted to start programming with Python. After some testing i wanted to do a simple Python bot. Basically all i wanted it to do was to calculate simple Problems. For example &quot;!calculate 22 * 2&quot;. My Problem is, that the operators -,* and / always return an error and + does the wrong thing. If the command is &quot;!calculate 22 + 2&quot; the output will be &quot;222&quot;. I don't know hot to fix this.
  I've already made a simple command-line calculator where almost the same script worked.
  Sorry if my english is bad and thanks to anyone who tries to help.
  Here's the part of the code with the calculator.</p>
  <pre><code>@bot.command(name=&quot;calculate&quot;, help=&quot;Calculates simple Maths&quot;)
  async def roll(ctx, number1, operator, number2):
  
  
  number1 = float(number1)
  number2 = float(number2)
  
  if operator == &quot;+&quot;:
      result=number1 + number2
  if operator == &quot;-&quot;:
      result=number1 - number2
  if operator == &quot;*&quot;:
      result=number1 * number2
  if operator == &quot;/&quot;:
      result=number1 / number2
  result=str(result)
  
  await ctx.send(&quot;Your result is &quot;+result+&quot;.&quot;)
  </code></pre>
  <p>I used the tutorial of <a href="https://realpython.com/how-to-make-a-discord-bot-python/" rel="nofollow noreferrer">Real Python</a></p>
  <p><a href="https://i.stack.imgur.com/MiOGD.png" rel="nofollow noreferrer">Discord Output.</a></p>
  <p><a href="https://i.stack.imgur.com/GBeq2.png" rel="nofollow noreferrer">VSCode Output, Error of the first command.</a></p>