title: Python - Wrong number of arguments exception?
body: <p>So I have a function like:</p>
  
  <pre><code>def my_code(arg1, *args):
      ....
  </code></pre>
  
  <p>And I want this function to only be able to take either 2 or 3 arguments (that means *args can only be 1 or 2 arguments). How do I throw an error message if the number of arguments is wrong? If I use a try/exception, is there a specific exception type for this?</p>