5 ms·
Everyone is a beginner before they become a practitioner. Look at Perl for an example of what happened to a language with syntax that appealed only to people w
by ForHackernews 6y ago
Everyone is a beginner before they become a practitioner.
Look at Perl for an example of what happened to a language with syntax that appealed only to people who were already Perl-practitioners.
- the_af 6y agoPG's point is that language syntax and notation should be aimed at practitioners. For beginners, almost anything will be a hurdle till the get the hang of it. Afterwards, they'll be practitioners. Being a beginner is a temporary situation; practitioners are forever.
- AnimalMuppet 6y agoAt the beginning, languages have zero practitioners. To at least some degree, they have practitioners in proportion to how many non-practitioners bother trying to become practitioners. The more off-putting the syntax is to a non-practitioner, the fewer bother to try to make the leap. Now, you are right that the syntax is for practitioners. But if it's too bizarre to non-practitioners, it is in fact a barrier to entry.
- striking 6y agoI'm pretty sure I hated writing Perl before, during, and after I was any good at it. It's unnecessarily full of ultra dense symbols, many of which are made dense for no reason. ($| means "hot pipes" means you want to flush all characters always. Set it non-zero to make it do that. Want saner names? Why don't you `use English;`, you rube?) Sure, being a beginner is a temporary situation, but let's not excuse absurdities and unnecessary convolutions as a result.
- the_af 6y agoIt goes implied in pg's remark, and my own opinion, that the notation must be good for practitioners. It's of course possible for notation to be plain bad for everyone. The argument actually says "don't optimize notation for beginners, optimize for practitioners". It doesn't imply making things difficult for beginners on purpose; just that they are not the priority.
- striking 6y agoI understand that, I read the remark. But you were replying to a comment about Perl, and I want to make it clear that there are plenty of people and languages that make excuses in favor of practitioners when it's convenient and that they shouldn't. I just don't even think it's a useful remark because you can just claim people you disagree with are beginners and people you agree with are practitioners and now anything can be argued.
- the_af 6y agoI wasn't commenting on perl, in case there's any confusion. I wouldn't call people who disagree with me on PL design issues beginners. I would call beginners beginners. It's not a matter of disagreeing, it's a matter of experience and time working on real projects with a language.
- nickjj 6y ago> For beginners, almost anything will be hurdle till the get the hang of it. Afterwards, they'll be practitioners. Being a beginner is a temporary situation; practitioners are forever. What about languages who support multiple ways to do something in a semi-inconsistent manner? For example with Elixir, in a lot of cases you end up calling certain standard library functions like foo(hello: :world) while others are foo(:hello, :world). Now, there's special magic happening in the first case but stuff like this is super confusing and it gets easily compounded with more complex examples. As a beginner I found Ecto's various ways to calls things super confusing and I had to reference examples almost all the time to get the syntax right (which often had multiple ways of being "right"), but I've also talked with more experienced Elixir developers and they get hung up with Ecto's syntax too. So where do you draw the line between making the language / DSL better and keeping it catered to only folks who are basically at the same skill level of the language creator?
- czynskee 6y agoI had (have) the same experience with Ecto but Ecto != Elixir. One of the super cool things about Elixir is how easy it is to extend the language with DSLs. However (and Jose et al are very up front about this), the more DSLs and macros you use, the more confusing it's going to be. Using macros is a tradeoff because it can be a very neat solution but it also obscures what the code is doing quite a bit. Re. foo(hello: :world) vs foo(:hello, :world) - that one I got the hang of more quickly, though I'll admit it's confusing at first. In the first you're providing a keyword list (which is merely a list of 2-membered tuples where the first member of the tuple is an atom). And when a keyword list is the last (or only) argument to a function it can be provided without the brackets. So the same thing could be written as foo([{hello:, :world}]) or also foo([hello: :world]). In foo(:hello, :world) you're just providing arguments. When you're first learning the language this can definitely trip you up but I think once you become a "practitioner" it's not too bad and ends up being pretty nice. God Elixir is so cool.
- the_af 6y ago> What about languages who support multiple ways to do something in a semi-inconsistent manner? They seem like a good thing to me! The aim is never to make things difficult for beginners on purpose. The point is that making things less confusing for beginners is not worthwhile if it comes at the cost of making things more cumbersome for practitioners.
- mcguire 6y agoThis explains the success of APL.
- the_af 6y agoIn case you're being snarky: it doesn't logically follow that because PL notation should optimize for practitioners, that any notation will be successful. It's possible for a notation to be bad for practitioners as well.
- dodobirdlord 6y agoThere’s a small group of people (financial analysts, mostly) who use APL derived languages, are hugely productive and make tons of money, and have no interest in changing the language they use. Not every tool is for every purpose and not every language should try to appeal to all users.
- Wezl 6y agoAlthough many of the APL derived languages changed their syntax by removing the fancy symbols. I'm not disagreeing, though: some people like them, some don't, and that's why people use j, k, and APL.
- agumonkey 6y agoI'd even go further, notation should never .. well that's too radical, rarely be a topic of discussion. Concepts are way more important. Spending time on syntax is like having a course in tar --flags.
- imtringued 6y agoWhat about beginners who stay beginners?
- tzs 6y ago> Look at Perl for an example of what happened to a language with syntax that appealed only to people who were already Perl-practitioners It became for several years one of the most successful and widely used scripting languages on Unix?
- sidlls 6y agoUntil languages with a different view completely left it in the dust.
- the_af 6y agoThere are multiple reasons why that may have happened.
- reflectiv 6y agoand a lot of them begin with 'perl is a mess...so...'
- RhysU 6y agoWell, we were all told that Python was easy and, lo, so it was. And that Perl was line noise and, lo, so it was. But I still find basic Perl to make as much sense as basic Python when I put my mind to it. And both to be painful in the wrong hands.
- tomc1985 6y agoSuch is the way of the world. The same will eventually happen with what is in vogue today, and detractors will appear seemingly out of nowhere to talk shit The idea that today's languages and technologies are truly better than the past is laughable, particularly when they recycle so much of what is old and slap on a new name
- sidlls 6y agoThe idea that today's languages and technologies are truly better than the past is laughable, That's really orthogonal to the discussion, though. This isn't about general superiority, it's about legibility and barriers to understanding/skill due to syntax and keywords. Perl is infamous for the "code golf is the default style" syntax, keywords, and tokens it employs in this context, and in my experience at least its most ardent fans believe it is a badge of honor. It isn't, really, and it's the same mistake PG makes when discussing "car", "cons" and the like.