title: Python :TypeError: this constructor takes no arguments
body: <p>When the user enters an email address, and the program reads the email and display it according to its criteria (e.g <code>yeo.myy@edu.co</code>), like criteria: </p>
  
  <ul>
  <li><code>username</code> is <code>yeo.myy</code></li>
  <li><code>domain</code> is <code>edu.co</code></li>
  </ul>
  
  <p>I know its something to do  with the <code>"@"</code>.</p>
  
  <p>this is the code</p>
  
  <pre><code>class Email:
      def __int__(self,emailAddr):
          self.emailAddr = emailAddr
  
  
      def domain(self):
          index = 0
          for i in range(len(emailAddr)):
              if emailAddr[i] == "@":
                  index = i
              return self.emailAddr[index+1:]
  
      def username(self):
          index = 0
          for i in range(len(emailAddr)):
              if emailAddr[i] == "@" :
                  index = i
              return self.emailAddr[:index]
  
  def main():
  
      emailAddr = raw_input("Enter your email&gt;&gt;")
  
      user = Email(emailAddr)
  
      print "Username = ", user.username()
      print "Domain = ", user.domain()
  
  main()
  </code></pre>
  
  <p>this is the error I got:</p>
  
  <pre><code>Traceback (most recent call last):
    File "C:/Users/Owner/Desktop/sdsd", line 29, in &lt;module&gt;
      main()
    File "C:/Users/Owner/Desktop/sdsd", line 24, in main
      user = Email(emailAddr)
  TypeError: this constructor takes no arguments
  </code></pre>