title: Tkinter Avoid Decimal Dot Repeatse
body: <p>So I have a very simple question as I am very new to programming. Pretty much, I'm building a calculator using tkinter and I have a decimal button and a decimal bind function to bind it with the dot (.). My small problem is that my Entry Widget allows the decimal to repeat when click on the decimal button a couple of times. For instance this could happen: 873...40..4. How can I make it so my entry widget recognizes that there are multiple decimal points in an integer and so it not allows that to happen.</p>
  <p>Here's something I've tried so far:</p>
  <pre><code>def key_decimal(number):
  
      string = e.get()
      e.delete(0, END)
      e.insert(0, string + '.')
      if string == int(string) + '..':
          e.delete(e.index('end') - 1)
  </code></pre>