Thank you so much! I'm glad you enjoyed it. If you don't mind, could you spare a few minutes to tell me things you like and didn't like? I'm looking to level up my writing. :)
And for a reader it's not easy to know if 3 is referred to either parameter, or at least is not explicit at all which makes life complicated with many arguments to specify.
Thank you so much! I'm glad you enjoyed it. If you don't mind, could you spare a few minutes to tell me things you like and didn't like? I'm looking to level up my writing. :)
ahha nothing I didn't like, the builder in Java is very verbose :D
BTW a little trick by more recent Python versions. You explained the problem with optional parameters, because you can do things like this:
And for a reader it's not easy to know if
3
is referred to either parameter, or at least is not explicit at all which makes life complicated with many arguments to specify.Since recently you can do this:
The compiler now forces you to specify the name of each optional argument
Oh that's super nice, I had no idea that was possible!
Yeah, it can also become a catch all for all unnamed optional parameters.