Yes, exactly. I mean, this dev is someone who clearly is working toward a deeper level of understanding of CS concepts, and here some people seem to be criticizing him for that. It's frustrating.
It really is. This "community" can be very unwelcoming. I'll never understand what motivates people to shit all over content they consider below them.
Is it really that hard to pass by without shouting "I'm smarter than you!" at everyone?
Almost always rooted in the person's own insecurities
There was a guy at the second-to-last place I worked who didn't know who Alan Kay was! What's worse, he wasn't ashamed of his ignorance.
At the last place I worked someone was refurbishing an old "expert system" written in CLIPS [1], he asked my advice and I said, "Consider using Prolog." He said, "What's Prolog?"
These are guys getting paid six figures and they do not care to educate themselves on the background of their chosen field. It's lame.
Could you imagine a physicist who didn't know who Newton was?
Then you missed the main point of the post, which was event flow, not state management. I'm wondering if sometimes older devs (I'm one) read these posts in anticipation, just waiting to find something that they recognize from elsewhere, just so they can say "aha, that's just X, nothing more!". In this case, you did recognize that yes, you can use a FSM to store application state, but the point of the article was much more event flow, specifically unidirectional UI architecture. It's not a new thing, by any means, but I thought it was a well-written post on how she/he expanded their understanding of this pattern.
> giving it all a new fancy name, and blogging about it
Are you suggesting that in this case, unidirectional UI flow is just another name for a FSM?
Yup. The UI reads its current-state data, which comes in on an event queue, and renders the display accordingly.
This is a state machine.
Are you seriously suggesting we abandon terms like "unidirectional UI flow" and just describe those architectures as state machines? You would be missing the most important part of the term, which is the flow of events. State machine says nothing about that.
I mean, if you're reducing the event flow of a UI to a state machine, why use the term MVC, right? It's just a state machine at heart, right? A lexer? Oh, that's just a state machine, forget about the term lexer. The various Markov models? Oh, just a state machine. etc. etc.
Fyi ... a meta observation about this type of discussion: https://en.wikipedia.org/wiki/Lumpers_and_splitters
It's an invisible underlying theme of many programming debates and the participants often don't realize it's happening.
(Personally, I like "splitting" for communication of nuance to others but I also like "lumping" to understand that many things are variations of an underlying principle. E.g. a "file system" is a "database" which is lumping but if I want to communicate to others, splitting is better and I'll call it the "Mac HFS file system" instead of "Mac database" which would just confuse the hell out of everyone.)
I totally understand your frustration.
This 17 or 18-year-old[1] didn't meet mmjaa's standards[2] to write about programming and apparently, many HN'ers feel the same way.
Maybe that's how the majority of HN community wants it to be. I honestly don't know.
[1] https://news.ycombinator.com/item?id=15116484
[2] a common "get off my lawn!" type of sentiment[1]: "To me, the "Full Stack" developer is simply someone who cares about whats happening under the hood. The "millennial developers" simply don't." -- https://news.ycombinator.com/item?id=14990097
The point is, this isn't a "new CS idea and technique" - in fact, this technique is as old as computer UI's themselves.
I have no idea how old this developer is, my only issue is that there is a re-invention of terminology and a whole new ontology being defined here, for something that has been a stock-standard CompSci concept for decades.
Its one thing to call me out as a grumpy old fart "not on my lawn"-ist - but its another thing to call out people who constantly re-invent the wheel and give it a new coat of paint, too. That is really my only motivation: to indicate that there is very little to be gained, productively, from ignoring the lessons of the past, "re-discovering" something, then slapping a new label on it. This doesn't do our industry any good - yet the practice is rampant. It seems, ever generation of CompSci graduates or so, someone gets the idea to invent something cool, which they've never heard of before, and proclaim that it is a unique insight into the field - whereas the fact is, its just a new coat of paint over an empty hole where the understanding should be.
We go through this psychosis every 4 or 5 years or so, in the computer world - so many times, we've re-invented the wheel and given it a new lick o' paint, calling it cool. I would, personally, like to see a bit more care given to this aspect of things by newcomers to this field - and rest assured, you can sit on my lawn as long as you cut it first.
Yes, the path most people will take today is from high-level languages and high-level abstractions, down to low level abstractions. It's not any better or worse than a bottom-up approach for learning. The fact that people are going down through the stack, trying to learn and understand things as they go is to be celebrated, not to be rued.
A top-down approach for learning makes logical and logistical sense in 2017, given the demand for developers operating on high-level abstractions. The bottom-up approach made sense, circa 1972 when C appeared. Neither approach is 'better', IMO.
I think the analogy holds here.
This analogy lost its sway for me with the word 'never'. It's not impossible, in either case.
Perhaps working with a small boat / low-level language is indeed 'harder', so you may be better equipped to deal with the higher-level easier language, after learning the low-level language. Teaching high level languages down to low level languages would be an increase in difficulty, and thus that becomes one logical path for learning. I'm not saying this path satisfies all learning use-cases, merely perhaps the majority in 2017.
I'm not familiar enough with sailing to say whether the same principle transfers to boats...
It's not about easier/harder. It's about responsibility and understanding.
Sailing a small boat is a "full stack" activity, from trip planning to navigation to the low level mechanics of jibing and tacking, even the act of physically keeping the boat upright if you're using a centerboard.
Sailing a large boat usually sees you in a specific role, doing a specific niche thing, and you never get an overview of the whole process.
The same applies to working in a large team of any sort, which is why you see software developers who can't write FizzBuzz but who nonetheless do fine in their particular niche.
-- Programming Pearls, Communications of the ACM, September 1985
On the other hand, so much gets done, it would be insane to go back to "C for all the things!".
It's a trade off, you're either a high level hacker, piping stuff together and watching for leaks, or your a low level system guy, squeezing the carpet.
The same argument ("so much gets done") was made for Visual Basic back in the day, you know. Oh, how the hoipolloi cried and crowed for the death of C developers back then. Oh, how they were wrong, oh so wrong!
I'm not saying the world doesn't have a debt to pay to the Node/Javascript camp - it surely does. I just feel that there is something really missing in the scene, if in fact things that C developers knew and applied well 'back in the day' are just now being re-discovered as "Cool New Shit™" by those who chose - willingly - to ignore the very mechanics of the components their stacks are highly dependent on.
Still, I guess its not worth complaining. Its good to know that JS guys can get over the wall, and discover that we've all been using state machines for decades now, and so on, eventually. I just wish there was a lot less hubris on the "crowing about it" side of things. Honestly, JS guys: you should know a little C. Its still there, underneath all the cool shit, and you're still heavily, heavily dependent on it, no matter what your "npm up" tells you...
Which is kind of true for us on Windows.
Most of the C has been replaced by C++, to the point that even the new C runtime library is actually written in C++ with extern "C" entry points.
Also for those of us on Android, where using the NDK is an exercise in patience writing JNI boilerplate, because Google doesn't want us using it more than strictly necessary.
Oh and the two most beloved open source C compilers (gcc and clang) are actually written in C++.
Now I admit that on traditional UNIX systems and embedded development on hardware constrained systems, getting rid of C is an impossible task.
As a person who works as a front-end developer but after hours writes almost exclusively in Rust I think I could shed some light on what's going on here:
Since JS is so accessible a lot of the folks who work with it don't even have a formal education in Computer Science(like the author, who's a CS student), so many of them never touched a compiled language in their life, not to mention subjects regarding CS.
To these people most of the concepts in C(like manual memory management) are entirely foreign. It's not that they don't _like_ C, it's that they're utterly unaware of the mindset one has to have to write things in it.
EDIT: grammar.
I have yet to see a job posting for a fresh-off-the-boat C developer. It's nearly always 5-10 years industry-related experience required. Web, on the other hand, seems more willing to take on the new guys.
And it was right, to the argument is moot. VB was a very productive language. Any issues where with the ecosystem moving on, not with VB (which had its warts, but all languages do, C first of all).
>Oh, how the hoipolloi cried and crowed for the death of C developers back then. Oh, how they were wrong, oh so wrong!
Again, they were right, oh so right. We do 1000x the programming we did in 1980 and 1990, but we don't use 1000x more C programmers (or assembly or pascal, two other popular choices at the time). Tons of code that used to be that, is now written in higher level languages.
Certainly, as a higher level programmer, I do think it is great to know as much lower level concepts as possible (it helps your higher level programming skills). But the truth is, business simply wants to Get Shit Done Fast. And having frameworks or libraries do a lot of the work for you saves a lot of time. Hence the huge amount of usage of "glorified plumbing" in the field.
(I don't think even C++ folks are immune to the "glorified plumbing" effect, eg: they have Boost, Poco, QT, etc.)
As far as I know, the separation between this side of programming and the more mathematical / inner detail "engineering" oriented side has always existed. (When I went to college, the "higher programming" pathway also had business courses, where the "engineering" side concentrated more on algorithms and the like. Now, even the business programmer folks did take one course in C++ back then...)
It's a trade off, you're either cut and paste blue collar programmer, piping stuff together and watching for leaks, or your a hacker/engineer guy, doing CS.
This is something that I try to impart on all new hires. Collective we have been making great strides in this industry lately, and in my experience, the more inexperience devs tend to get blinded by all of the shiny. This isn't inherently bad; a lot of CS breakthroughs are tough to learn without the appropriate domain knowledge. But practical stuff that most devs use ins't anything fancy. It's the same concepts from years ago with config files attached to it.
We don't stress learning algorithms so that you can write a perfect quicksort implementation from memory. We want you to know the fundamentals so that tomorrows new technology becomes trivial to learn.
Also SICP/HtDP
2. The core requirements for a cs major at a typical university (read: not CMU,MIT,Stanford,Berkeley) and especially at a non flagship is basically 4 or 5 courses, which you can for sure cram into 6 months if that's all you're studying.
Personally, I'd rather work with people who learn some part of that on their own (or even not at all) but have a stellar education in reading, writing, and math. The former are often provided by good high schools. The latter not so much. At least in the states.
But if all you want is just the core fragment of just the cs, six intense months are enough.
Not at my university, with the amount of stuff we had to do, unless in the 20+ years that have gone by, they got the quality level down.
No, you cannot cram an entire degree into six months. Hence the second paragraph under my second point.
But the core CS sequence? 4-5 courses is a rough semester, but it is a semester!
And if you already have some mathematics or especially some programming background, the sequencing that causes those courses to stretch into 1.5 years is already resolved.
Some people managed to jungle a few more courses.
I don't see such a program being much more than simple introduction to CS.
No, you're not going to be publishing papers or talking through OS implementation details with CMU grads or designing computer vision systems with Berkeley grads. But you'll have the baseline knowledge that agumonkey is referring to in their comment.
I went to a school that is very far away from CMU, MIT, Stanford, Berkeley, etc and my core requirements were A LOT more than 4 or 5 courses. I'd have to check by I can name at least 8 core requirements off the top of my head.
> which you can for sure cram into 6 months if that's all you're studying
So your suggestion is for people to look at a CS syllabus and find a way to teach themselves all of the core courses?
I have my bachelors in CS. I never really programmed until college. 6 months into my BS I had barely wet my feet with Scheme, learned a little bit of discrete math, and had a VERY basic introduction to formal logic. I knew exactly one programming language.
I'm familiar with a vast array of CS curricula at many types of institutions. I have no doubt that this is true, but it's also not universal.
To be clear, I'm referring to the courses that everyone from that institution will have taken before graduating. So almost all CS majors require much more than 4 courses, but only 4 courses worth of certain, common, shared knowledge.
If you only count courses offered by the CS department, and that everyone must take to receive a major, I think 4-5 is fairly typical. Maybe 6-7. Especially at places that aren't ABET.
Most programs will also require 3-4 additional courses for the major (that the college/university does not require for graduation). E.g. at least one or two mathematics courses, sometimes a Physics course.
And of course all those programs require some electives -- sometimes selected from subject area "buckets".
But my point is that it's certainly possible for two students to get a CS degree from the same (decent or even good) institution and only share 4 "core" CS courses. Typically an intro course or two, a lower-division algorithms-style course, something architecture-y, and something systems-y.
> So your suggestion is for people to look at a CS syllabus and find a way to teach themselves all of the core courses?
Maybe.
This approach would certainly be inappropriate for a student with no background in Mathematics or programming.
But a strong programmer can breeze through or even skip those intro courses.
And a student with a strong mathematics background -- e.g., an accountant, other science major, or finance person learning to code -- can breeze through that otherwise time-intensive algorithms course.
Huh? That's an incredibly terrible CS curriculum. 4-5 courses is at most 20 credit hours. A typical undergrad degree requires about 120 credit hours of courses before you can graduate. I went to a second tier state school and our CS curriculum had 12 common required courses (excluding seminar courses) that everyone took, plus three upper level electives of your choice. Basically half of the four year degree was CS.
I'm talking about the set of courses that are 1) offered by the CS department and that 2) every student must take.
Not even the entire set of cs courses. Just the ones every student must take.
> A typical undergrad degree requires about 120 credit hours of courses before you can graduate*
Obviously you cannot get an entire degree in 6 months. You can't even finish all of the required coursework.
That's why I said "core CS sequence", not "a degree".
As I said, that was a dozen courses at my school.
Either way, that level of straight-jacketing and/or in-sourcing is atypical.
Even at top schools that number is usually below 10. E.g. CMU 6 (well 7, but really 6); Berkeley 4-6; MIT 8; Standford 6.
These are all off the high end of my 4-5 estimate, but only because they ALL in-source a course that at most places would be farmed out the math dept and therefore not counted by my criteria. And MIT also a comm course. Plus, there's the other extreme of places that only require the intro sequence and an algorithms course, leaving all else to the students.
In order to get up to 12 at any of these places you'd need to only offer one course for a lot of the "breadth" requirements, or else in-source the calculus sequence (or similar silly things).
Again, I'm counting courses offered by the CS dept, AND that everyone takes. The minimum viable "common knowledge" we can reliably assume is shared among all CS majors, as offered by the CS dept. IME 4-5 is pretty typical. Maybe 6.
Yes, we also assume some background in other fields of study from CS graduates (some calculus, reading/writing skills, etc.) But those courses are not the ones I was referring to with my 4-5 count. They were also addressed in my original comment.
I don't think it's very atypical, for example take a look at this course requirement for City College of New York under CUNY :
https://www.ccny.cuny.edu/sites/default/files/csc-prereqs-04...
Under the CS parts, only the elective in category A, B, and C is where student can pick and choose. Everything else under the grey curve across the pdf are:
> courses offered by the CS dept, AND that everyone takes.
I don't feel bad about this at all, since my colleagues describe me as a competent developer and my employer can't find enough people for all the work we have to do. If we only wanted to hire developers who understand C, we'd have a really big issue.
I had a choice at one point : Join the workforce doing web work (and make money right now) vs. spend more time in school and learn more while gaining debts and making no money.
Right now I am debt free, living a good life writing modern JS.
In my free time, I try to learn more low-level CS knowledge. It's however hard to justify the time spent doing this since none of it is of use during my day job.
If University was free and we didn't have to work to eat, I would know everything from the ground up. Sadly, this is not the world we live in.
However, it always amazes me how powerful abstractions such as high-level languages are. In particular, it allows people who know virtually nothing about the underlying mechanisms to develop cool applications. This is a great thing, and I think we should value it, even though it comes with some major problems.
I meet quite a lot of low to middle level programmers that stick to what they know because it's "the basics", and hence completely lack in experience in:
1 - Writing elegant modern code
Working with experienced C / Java coders to write proper Python is a challenge. They tend to use twice to many lines, ending up with slower and less readable code. They don't use the additional productivity to produce cheap goodies like generated doc, more unit tests, etc. They over-engineer stuff, but let the user experience down. And don't ask them to setup a server without the help of a sysadmin.
2 - Trading efficiently machine time for coder time
Aka you cost 100 $/h, a bigger server cost the same amount a month. Keep the double nested loop and go code something else.
And please setup code auto reload and preprocessors. Because THAT will save time and money down the road.
3 - Knowing the modern ecosystem and how the stacks fit together
No you don't need share this across threads and set a mutex here, put that in redis.
Don't write that in XML, you have JSON/YAML/TOML for that.
Actually don't write that in a file, you have sqlite.
No, you don't want to JOIN that, you have Arrays and JSON types in PostGres. If you got a lot of those, mongo or elastic search will do.
No you don't write sockets manually, you have http, zeromq, wamp and the likes to do 99% of the jobs.
JSON is too slow ? You have bson, msgpack, protocol buffers...
Yeah, this ORM is slow. But it generates the entire validation system, including HTML forms. And it allows for 12 plugins to share a common API to provide auth, history, permissions, registrations, a REST API, security measures, sanitizing and data validation for free. Plus the server has 32 cores so just go with it.
4 - being able to keep up with user expectations
No I have no idea how to code in assemble. I can tell you however that the search completion you don't want to add here because it's too much work would prevent the user to think your app is from 2004. And I can get decently performance version of it for tomorrow at a cost effective price.
----
Bottom line, everybody has limited time and resources and can only learn so many things at once.
Also different industries have different needs. And sometime you want low level programmers, sometime you want high level programmers.
One could hire somebody who has the skills of both, but you probably can't afford him or her. And he/she is probably not interested this mission anyway
2) Funny, there's a near-constant stream of articles on how companies who succeed have to spend significant amounts of money money and time re-write their code, because those nested loops weren't just fast enough, and were causing the company to hemorrhage money.
3) "put that in redis" At which point you incur a network roundtrip to the redis server.
"you have JSON/YAML/TOML" So, which one? They're not cross compatible. Oh, and don't forget to add custom encoding for non-JS compatible values. JSON is just the latest iteration of XML these days, complete with XSLT, X-Path, XSD, processing directives, and namespaces.
"you have sqlite" SQLite has been available for decades, and in use by programmers just as long. Oh, and it's written to a file on the filesystem. And doesn't support transactions.
"Arrays and JSON types in PostGres" Oof. Hope you don't want performance to go with that. Joins are much more performant, and have the bonus of being flexible when the user spec changes.
"You have bson, msgpack, protocol buffers" Binary serialization formats have been around as long as there have been computers. People have been sending raw structs with checksums over the wire as long as there have been wires.
"Plus the server has 32 cores so just go with it." This again. Doesn't scale, and will cost your company when you do have the scale.
4) I'll be honest, I don't get your point here. Low level programmers can't keep up with user expectations? Why do you think `ls` has several dozen flags? Users wanted them.
The amount of oversimplifying you're doing seems to skip every flaw in your argument in my opinion. That's not to say you're necessarily wrong... a C programmer probably isn't worth it over a Python programmer. But writing code with double nested loops for no reason or ignoring basic algorithms is going to cost you big time in the long run.
As for the doubled nested loops, as usual, it depends. Data size, boudaries, number of concurrent operations, cpu costs, acceptable loading time...
On (Debian) linux boxes apt-get install <package>-dev and away you go, there's literally the whole platform ecosystem there for you to use.
I don't think that is just today (except the blogging aspect). That is how it always has been. Developers learn from experience, learn from doing.
Is this the state of things today - that kids start off as highfalutin' "developers", whereby 95% of their apps are written by others (because: "npm -i <all the things>"), and then .. eventually, from the top-down, trickle through the stack learning "the things", giving it all a new fancy name, and blogging about it? Because to me, this seems more like devolution at work in the computer science industries, not some kind of radically derived insight.
I'm not trying to be overly critical, but for a lot of us, "discovering that C-based apps are, weirdly, similar to what us React-ites are doing" sure seems like a step backwards from real stack competency.