title: Python syntax errors - coin machine problem
body: <p>I know these are very basic questions but cannot figure out what I'm doing wrong. I'm just beginning to learn python and don't understand why I am getting a syntax error every time I try to subtract something.</p>
  <p>When I try to run this:</p>
  <pre><code>```#def variables - input cash entered and item price in float parentheses
  cash = float(400)
  price = float(215)
  
  #change calculation
  
  def cash_owed(cash - price)```
  </code></pre>
  <p>I get a</p>
  <blockquote>
  <p>SyntaxError: invalid syntax with the ^ pointing to the - sign.</p>
  </blockquote>
  <p><strong>I can't find any information about why using a subtraction sign would return a syntax error in this context. What am I doing wrong?</strong></p>
  <p>I am trying to create a coin machine program where the cash is entered in integers representing cents (i.e $5 = 500) returns the required change in the most convenient coin denominations. This is the rest of the code that I wrote, but I can't even get past that first syntax error.</p>
  <pre><code>cash = float(400)
  price = float(215)
  
  #change calculation
  
  def cash_owed(cash - price)
  
  c = cash_owed
  
  #display amount recieved, cost of item, required change
  print (&quot;Amount recieved : &quot; + str(cash)) \n
  print (&quot;Cost of item : &quot; + str(float)) \n
  print(&quot;Required change : &quot; + str(c)) \n
  
  #calculate toonies owed
  def calculate_toonies(c//200)
  round(calculate_toonies)
  
  print(&quot;Toonies x &quot; + str(calculate_toonies))
  
  c = c%200
  
  #calculate loonies owed
  def calculate_loonies(c//100)
  round(calculate_loonies)
  
  print(&quot;Loonies x &quot; + str(calculate_loonies))
  
  c = c%100
  
  #calculate quarters owed
  def calculate_quarters(c//25)
  round(calculate_quarters)
  
  print(&quot;Quarters x &quot; + str(calculate_quarters))
  
  c = c%25
  
  #calculate dimes owed
  def calculate_dimes(c//10)
  round(calculate_dimes)
  
  print(&quot;Dimes x &quot; + str(calculate_dimes))
  
  c = c%10
  
  #calculate nickles owed
  def calculate_nickles(c//5)
  round(calculate_nickles)
  
  print(&quot;Nickles x &quot; + str(calculate_nickles))
  
  c = c%5```
  </code></pre>