title: Can someone help me with formatting this to the form of a phone number: 000-000-0000
body: <p>How can I print the number like this &quot;641-648-4685&quot;. The code works for me but the number formating is the only problem</p>
  <pre><code>    def __init__( self, name, area_code, number, is_active = True):
          self.name = name
          self.area_code = area_code
          self.number = number
          self.is_active = is_active
          
      def __str__(self):
          return str(self.area_code)+'-'+str(self.number)+&quot; (&quot;+self.name+&quot;)&quot;
  
      def __eq__(self, other):
          if self.area_code == other.area_code and self.number == other.number:
              return True
          else:
              return False
  
      def activate(self):
          self.is_active = True
  
      def deactivate(self):
          self.is_active = False
  
  phone1 = Phone(&quot;HU&quot;, &quot;641&quot;,&quot;6484685&quot;)
  phone1.deactivate()
  print(phone1)
  </code></pre>