Related to it, it would be interesting to roughly categorize people that answered the Twitter thread in
People that only experienced JS
People that experienced JS and TS
People that experienced JS, TS, and a statically typed language like Java, not based on the Hindley–Milner type system
People that experienced JS, TS, and a sound static language like Haskell, OCaml, Elm, or F# based on the Hindley–Milner type system (where type annotations are mostly optional)
"It's usually helpful to write down the type of new functions first;"
I always thought that it is useful to actually separate the type from the implementation - as opposed to the C-style conflation of both. So something like
"It's usually helpful to write down the type of new functions first;"
Yes, it is interesting to note that devs that use languages where type annotations are optional end up with a mindset of writing type annotation first and the implementation after.
Programming languages influence the way we find solutions.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
The "Ideology" video linked is very nice.
Related to it, it would be interesting to roughly categorize people that answered the Twitter thread in
On a side note:
A Gentle Introduction to Haskell, Version 98
"It's usually helpful to write down the type of new functions first;"
I always thought that it is useful to actually separate the type from the implementation - as opposed to the C-style conflation of both. So something like
seems perfectly reasonable - though familiarity with the mainstream, conflated syntax
creates a bias towards
s: string
"belonging together" even though they are just distinct aspects of the same positional argument:s
is the name the value of the positional argument is bound tostring
is the type the positional argument is expected to beYes, it is interesting to note that devs that use languages where type annotations are optional end up with a mindset of writing type annotation first and the implementation after.
Programming languages influence the way we find solutions.