title: Python for-loop runs twice, even with breaks
body: <p>I'm working on a text-based RPG on my free time for fun, and I've begun implementing barter, thievery, and shopping systems for NPC interactions. Bartering works, as does thievery, but purchasing items for in-game money does not. All of the mechanics work, but for some reason the for-loop runs twice! I even tried implementing an integer to constrain it to one purchase, but it doesn't help either. I've provided the code for the <code>selltoplayer()</code> function.</p>
  
  <p>Keep in mind that everything is working, except for the loop continuing after the breaks.</p>
  
  <pre><code>def selltoplayer(self, player):
      inv = self.readableinv()  #Give us a viewable inventory
      print("What would you like? I have the following items in stock:\n{0}".format(inv))  #display said inv
      purchaseitem = input("Type the name of the item that you wish to purchase:\n")  #Get the requested item
      timespurchased = 0
      for item in self.inventory:  #search each item in the inventory
          if timespurchased &lt; 1:
              if item.name == purchaseitem:  #once the correct item is found...
                  ImportantCalculations.determinevalue(player, item)  #get the item's value
                  if player.money &gt;= item.buyvalue:  #and make sure that the player can afford it.
                      confirm = input("So, you would like to purchase {0} for {1} Karics?\n".format(item.name,
                                                                                                item.buyvalue))
                      #Just a simple confirmation
                      if confirm.lower() == 'y' or confirm.lower() == 'yes':  #If the player would like the item
                          print("Thanks for your purchase!")  #the merchant is kind
                          player.inventory.append(item)  #put the item in the player's inventory
                          self.inventory.remove(item)  #take the item out of the merchant's inventory
                          player.money -= item.buyvalue  #withdraw the proper amount of money from the player's stores
                          pinv = player.readableinv()  #Readable inventory for player
                          print(pinv)  #Debug line to make sure that the item was properly transferred
                          print(player.money)  #Debug line to make sure that the money was properly transferred
                          timespurchased += 1
                          break  #stop
                      elif confirm.lower() == 'n' or confirm.lower() == 'no':  #If the player made a mistake
                          print("Oh, okay.")  #Try to guilt the player out of leaving
                          exitsell = input("Would you like to browse again (A) or exit (B)?\n")  #ask if they want to
                          #purchase something different or leave
                          if exitsell.lower() == 'a':  #resell items
                              self.rselltoplayer(player)
                          elif exitsell.lower() == 'b':  #exit
                              print("Thanks for stopping by!")
                              break
                          else:
                              print("Sorry, I don't speak gibberish. I'll see you around!")
                              break
                      else:
                          print("Sorry, I don't speak gibberish. I'll see you around!")
                          break
                  else:
                      print("I'm sorry, but you cannot afford this...")
                      self.rselltoplayer(player)
          else:
              break
  </code></pre>
  
  <p>Here is what happens when I run the file:</p>
  
  <pre><code>What would you like? I have the following items in stock:
  
  ['Stick', 'Rock', 'Scarf', 'Explosives', 'Diamond Ring']  #Prints inventory fine
  
  Type the name of the item that you wish to purchase:
  
  Stick
  
  So, you would like to purchase Stick for 104 Karics?    #Interprets player choice properly (including the value)
  
  yes
  
  Thanks for your purchase!  #Interprets confirmation fine
  
  ['Stick']  #Prints player inventory fine
  
  396  #Prints player money fine
  
  #Then... It loops again.
  
  What would you like? I have the following items in stock:
  
  ['Rock', 'Scarf', 'Explosives', 'Diamond Ring']
  
  Type the name of the item that you wish to purchase:
  
  Scarf
  
  #And doesn't even complete. What's going on?
  
  Process finished with exit code 0
  </code></pre>
  
  <p>Feel free to ask if there isn't enough information.</p>