Python Forum
Function parameters - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: Function parameters (/thread-8214.html)



Function parameters - grkiran2011 - Feb-10-2018

Hi Viewer,

While defining function parameters we should pass the dynamic keyword argument (**kwargs) at the end. Otherwise python throws a syntaxerror. Is it just that the syntax has been defined as such or is there any particular reason behind this.


RE: Function parameters - buran - Feb-10-2018

can you share your code (in code tags) that throws an error? Also include the full traceback in error tags


RE: Function parameters - Gribouillis - Feb-10-2018

It is defined by the syntax. It has always been like this. I suppose the reason is that arguments that come before are called "positional" arguments, and they need to be at a specific position.