I teach it to complete beginners to programming and generally it goes great - there is a huge demand for junior Scala developers in my neck of woods.
However when I found that 22 argument monster a while ago it was a bit of a wtf moment to me.
Why 22? Why not 21 or 23 ? Is it one of those no one is going to need more than 22 arguments?
> Is it one of those no one is going to need more than 22 arguments?
You can work around this limit with nested tuples, or just defining Function23 yourself. Although if your function accepts 23 arguments, you should probably refactor that anyways.
It is also worth noting that Scala 3 drops this limitation by implementing function arguments with arrays: https://github.com/lampepfl/dotty/pull/1758
I teach it to complete beginners to programming and generally it goes great - there is a huge demand for junior Scala developers in my neck of woods.
However when I found that 22 argument monster a while ago it was a bit of a wtf moment to me.
Why 22? Why not 21 or 23 ? Is it one of those no one is going to need more than 22 arguments?