Hacker News new | past | comments | ask | show | jobs | submit login
Programming is Easy, Software Development is Hard (thoughtclusters.com)
79 points by Garbage on Jan 24, 2011 | hide | past | favorite | 50 comments



Programming isn't that easy. I've been trying to teach some friends who've expressed interest for years. It seems rote and simple to me, but even working with them one on one doesn't seem to work. I've tried analogies, metaphors, and diagrams; I've tried to start from the high-level over-view and from the nitty-gritty. Some of them make a little head-way, but most have given up.

I think it has something to do with the cognitive load of assimilating language. A lot of what makes math hard is the language of math. Those that understand math find the language to be the easiest part and by far the most mechanical and simple to understand. Yet not everyone can pick up new languages. Most people as I understand it only have room in their heads for one or two. I would wager those that learn math or programming might have room for a little more. To learn a language is rote excercise, but not everyone can retain it for some reason afaik.

I think most people can learn what a "variable" is and might understand assigning a number or a "string" of letters. Yet even understanding arrays, hashes, and such low-level primitives is difficult. Going beyond that into functions, operators, generators, classes, objects, closures, data structures, memory allocation, pointers, references, etc... forget it. It takes a certain kind of person to be able to assimilate all of that and use it effectively.

Why else do we continue to invent languages "for people who cannot program?"

It's hard for a master to think like a student.


My wife is a smart person. She's a seismic geologist, she can do calculus, she has no problem thinking in her domain's language and concepts, and memorization of information has never been a problem. She's asked me to explain basic programming concepts a few times.

She can't or won't make the mental leap from basic algebra skills to variables and functions. Mentally unrolling loops or recursion, forget it. I don't even bother trying to explain data structures like stacks and heaps. How a programming language [that's mostly human readable] gets turned into machine interpretable information is black magic. She even took an intro to programming class as part of her degree, so I'm not the only teacher who's failed at the topic. It can really be frustrating at times because I have a respectable knowledge of geology and its industries and can conversationally hold my own with her and her peers, but she can't reciprocate at all with my peers.

For my sanity, I've always assumed some people just can't readily grasp the abstract symbolism and recursiveness programmatic thinking requires.


I think CS is so new that we don't quite have a grasp on what is truly hard and what is merely being explained badly. That's nothing against your teaching skills; I mean that our mental model of functions and recursion may be unnecessarily complex, or mixed in with other things, or perhaps depends too much on visual or symbolic thinking.


As the grandparent said, "It's hard for a master to think like a student."

This is perhaps the biggest obstacle for people who are trying to teach others to program - and so I agree with you here.

However, it does seem like there are some people who will just never be able to pick it up - even though they are demonstrably smart in other areas.


I don't buy that. That's like saying some people are smart enough to read, but just can't figure out writing.

There will always be those with exceptional aptitude. But if you must be exceptional to simply understand a subject as broad as computer science, that's a problem with how we conceive the science.

The Romans thought multiplication was really hard, too. Exponents were literally unthinkable. We know better not because we're that much smarter, but because we have a simpler and more powerful way to think about it.


Although seismic geology will have a 'language', it's no where near a programming language. Most specialisations say 'we have a language' but that mostly means they have lots of specific terms or common-for-them-uncommon-for-the-rest-of-us words. Whereas a programming language is much more like a real human lanuage than a lexicon.


Yes, but we also have non-programming vernacular that we use outside of the act of programming that encompasses CS concepts. It's a bit like having a specialized vocabulary to describe another language.

I can conversationally say to fellow computer scientist "I organized the pieces of data into a red-black tree" and that's totally programming language agnostic and conforming to English syntax while still requiring a hefty amount of CS knowledge to grasp the actually meaning of what was said.


Some people find programming easy.

I was well into my twenties when I started programming, but I found the logic very natural - if this do that, otherwise do something else.

A friend of mine was skilled in natural languages (she spoke several languages reasonably well) and wanted to learn programming (it's just another form of language, right?), but she gave up after a semester - she found programming languages to be hopelessly nitpicky with nonsense rules and no relation whatsoever to languages used to communicate between humans.

For some segment of the population the basic premises of programming come easy, and it's just a matter of spending time enough to learn the details.

Others struggle mightily with the same basic premises, it seems like they can't really switch to the "extremely narrow minded one step at a time and you can't substitute uppercase letter O for numeric zero even though the look the same" frame of mind that is a prerequisite for doing any kind of programming in any language.

It's possible that programming is learnable by everyone, but it certainly seems to come more natural to a few.

I suspect that the difference is more deep seated than we normally give it credit for, possibly even somewhat analogous to the mix of "fast twitch" and "slow twitch" muscle fibre (http://sportsmedicine.about.com/od/anatomyandphysiology/a/Mu... ) that can give someone a natural advantage in certain kinds of sports.


... she found programming languages to be hopelessly nitpicky with nonsense rules and no relation whatsoever to languages used to communicate between humans.

I find that funny. Has she tried learning Russian?

As far as being "just another form of language;" I think the assumption is quite reasonable. However, like any significantly complex language it's easy to learn enough to get around and order dinner. But to be conversant enough to explain to someone how to perform a complex task in that langauge is quite another. I read somewhere once that people generally only have a certain amount of space in their brains in which to assimilate a language to such an extent.


A Russian won't throw an error (or anything else) at you if you conjugate a verb slightly wrong in a sentence where the meaning is otherwise clear, but a programming language will error out if you accidentally type two periods instead of one. Even the pickiest of human languages will generally be heard by listeners far more forgiving than a compiler.


You still need to be a sufficiently proficient speaker of Russian to get to a point where a slight mistake of inflection is so easily forgiven.

Similarily, once you are well versed in a programming language the compiler really stops bugging you about trivial errors in syntax and grammar.

However, it still won't forgive you if you make them. Just as I won't forgive people when they make glaring mistakes in their use of English. Yes I can still understand them, but I have the advantage over a computer -- there are probably half a dozen non-verbal cues that I can use to decipher your intended meaning (and is probably why online discussions are so prone to turning into flame wars).


I agree that it's not easy for some. I watched a group of intelligent people who'd forgotten all their high school math try and learn programming for 9 weeks and it was unproductive. Math builds abstraction upon abstraction, and programming does too.

There was a study two years ago showing that learning maths literally rewires your brain (noticeable on scans)... so it's not just a matter of adding some more knowledge - it's a different way of thinking.


According to this paper http://www.eis.mdx.ac.uk/research/PhDArea/saeed/paper1.pdf the greatest hurdles are usually:

assignment and sequence recursion / iteration concurrency


There is a very easy way to explain programming (in assembler, no less) by analogy to how children do basic mathematics -- addition and subtraction.

That's because mathematicians do use algorithms, and concepts like "position" (indexing to us programmers), though they don't have names for them. If you explain programming using the concrete things every educated person knows, it is much easier to teach.


I think David Brooks article, like the article on the Rhodes scholars, are very partisan ideological articles, although both disguised quite nicely.

The conservative right has started a grassroots movement to make traditional measures of intellect and achievement worthy of less distinction. A PhD? Who cares? Nobel Prize in Chemistry? Chemistry isn't that big of a deal, anyone can do it. Plain talkin' people who struggle with things like math and science -- those are the real intellects. Because being an intellect is being someone who can just relate to the every day man. Everything else is just a "hobby" that is no more worthy of distinction than being good at Call of Duty.

Over 2011 expect a full court press on this. Academia, scholarship, science, math, etc... will all be attacked as not particularly interesting. Plain spoken populism will be the new metric for brilliance and the best this country has to offer.


You may have a point here, but ain't it a shame how we have to backtrack and defend against perspectives that are wholly reasonable, because they are the proverbial "camel's nose in the tent" for some backwards claptrap?

I say we agree that yes, a Nobel Prize winner might not be destined to become a world-class CEO or whatever. The place to hold the line is in the value of their contribution.

Perhaps we can spin this potential trap back towards reality. Really, when someone becomes a flawless violinist, or programmer, or chemist, what they have made is a tremendous sacrifice. Being best in the world at those things means letting other parts of your mind lie fallow.

I think I might have been more fun to have dinner with when I was in punk bands and reading more books. By dedicating myself to tech I'm probably making a bigger difference in the world, but at some cost to my well-roundedness.

We should laud the winners of intellectual pursuits for the sacrifice they have made for the rest of us.


Interesting prediction, and I kindof suspect there's a kernel of truth to it.

Of course, what you refer to is just marketing, which will result in underestimating the utility of having these degrees. The fact remains, however, that it still matters if you're well-educated, and it's still going to be causal when it comes to earning income or influencing your sphere.

All that changes is the value - elite topics will be undervalued, so it will be a great time for those who are intrinsically motivated to enter academia.


It's way more complicated than that. Telling people all about how gloriously hard science is may not be the best way to get them into science, for instance.

The right would be having less success with its "movement" if science had done a better job of policing themselves and staying scientists. Instead, across a wide variety of fields, they've been getting into politics. Now they are beginning to experience the consequences, and frankly, "the right", bogeyman or otherwise, isn't entirely wrong here. We don't need more politicians, we need scientists.


Would you like to give some concrete examples of scientists "getting into politics" preferably with quotes?


Oh, please. Global warming, nutrionists, environmental issues in general (on both sides, not just government funded), activist medical scientists, if you don't already realize this you'll probably explain away anything I would produce. This is endemic, not isolated.

It doesn't count that it's really important!!, like the global warming scientists. It's still scientists in politics, not merely saying what is happening but what we should do about it and when. It doesn't count that you like what the political scientists are saying, it's still scientists in politics.


This is insincere. Scientists have been in policy since the beginning of time. Some of the greatest scientists in early US history were literally politicians. But beyond that policy makers routinely have gone to scientists for recommendations. From where to find fish and gold, to which foods to eat to prevent illness and disease. These predate the US as a country.

The big problem is that when science goes head to head with the "politics" of the day then there are problems. Galileo encountered this, as did even Darwin (he elected to withhold publication to avoid many problems). The end result in the short-term is the scientist is ostracized ... the long-term vindicated.

Now maybe you're asking scientists to do the same today. Don't publish papers or offer recommendations if it will ruffle feathers. I'm sure many scientists do this, but frankly I don't think this is a satisfactory answer.


Oh, so you don't have any concrete examples. Try to find some, the experience might teach you something.

Edit: on re-reading, that sounded way snarkier than I wanted. What I mean is, actually do the exercise of trying to find quotes of scientists playing politics. It's not as easy as you seem to think.


"James Hansen". Pretty much anything he's ever said in public. No, it's not hard at all. It's hard to find a scientist's name in the (conventional) media who is not playing politics. (In this case I don't include the explicitly-science section of the papers. There you get your choice of either a journalist playing politics with science or a journalist not understanding what they are writing about, or both, but that's not the scientist's fault.) You think it's hard because we've become so used to it you can't see it anymore but scientists do hardly anything but make ought statements instead of is statements anymore.


>nutrionists

Most of those people aren't scientists.


I think you're reading too much into Brooks' ideology from that singular article and that singular excerpt. Based on my experience with other works from him and from listening to him speak on PBS news, it's disingenuous to lump him in with the "conservative right". He is anything but anti-intellectual.

That said, his position is not that "plain talkin' people who struggle with math and science" should be lauded but that social skills are not skills that can be learned through formal education. His point is that group dynamics, being able to read people and lead people, is a very subtle art that is learned throughout childhood and adolescence and Chua denied her children the opportunities to learn these skills by refusing them sleepovers and plays and such.


He's certainly part of the conservative right. He's no Michelle Malkin, but he's considered the NYTimes right-wing opinion columnist.

His point is actually slightly different than what you are saying, and this subtlety is important. Because while Brooks is on the right, is one of their more astute thinkers. Brooks is actually saying that formal education is easy. Not intellectually challenging, and largely a playground. Lets take some quotes:

"I believe she’s coddling her children. She’s protecting them from the most intellectually demanding activities because she doesn’t understand what’s cognitively difficult and what isn’t."

"these and other social tests impose cognitive demands that blow away any intense tutoring session or a class at Yale. "

"Chua would do better to see the classroom as a cognitive break from the truly arduous tests of childhood"

He's not simply saying that there exist other skills that aren't taught in the classroom and that these ar also important and difficult. He's saying something much stronger. He's saying the things that people like Chua value (math, science, arts, literacy, etc...) are the easy things -- the things not to be valued. They're the things you do when your child needs a break or to be coddled. These are the things of intellectual lightweights.

The hard cognitive work is the stuff you see at the corner store in Smalltown USA. These people don't have college degrees, PhDs, Fields Medals, but they can do the actual intellectual demanding activities, not the stuff "you coddle your children" with.


> He's saying the things that people like Chua value (math, science, arts, literacy, etc...) are the easy things -- the things not to be valued.

Again, he is not saying this and you are also leaving out the quote at the end which is:

"I wish she recognized that in some important ways the school cafeteria is more intellectually demanding than the library." Emphasis mine.

Please read this article from him and then come back here.

http://www.nytimes.com/2010/09/10/opinion/10brooks.html?ref=...


That linked op-ed on the "softening" of American jobs just gracefully skips over the fact that those hard-nosed, hard-chargin' back-breakin' jobs he wished we all had (as he sits in an industry that is so completely the opposite of that) have all moved to China and other places where cheap labor is the ultimate advantage. We can keep graduating Mechanical engineers until the cows come home, but if someone can make more money (or, indeed, any money at all) being a stock trader or realtor, most would consider ME a dying industry in this service-based economy.

He seems to focus on industrial entrepreneurship, a capital-intensive proposition to be sure. I peg Brooks as a "supply-side" kinda guy, so he would probably point to tax cuts as the divining rod of spurring entrepreneurship in that area. Thing is, you can cut taxes all day, but if the bank won't lend you any cash because they're not lending anything much less to your really expensive first-time venture, tax cuts aren't gonna help.

And, VC cash is hard to find in the US unless you're doing software, consumer, web, mobile, or cleantech. If you're in "old line" tech like medical devices or consumer electronics, forget it. Overseas is where to go. Open up shop in Singapore if you're building the better artificial heart.


First, read the article yourself. You appeared to have missed the 700 words that preceeded that sentence.

And even that sentence you quote is completely ambiguous. Is he arguing that they're equally demanding? Or that the important ways that matter the school cafeteria is more demanding than the library or vice-versa? You can't tell from that one sentence. But if you read the whole article you can tell what he actually believes. Read the quotes I have from above that are NOT ambiguous. He clearly states that the library is LESS intellectually demanding. No ambiguity, no qualifier.

Read the article in full then come back here.


If you would read the link I posted above, your misconceptions about his agenda would be cleared up.


His agenda is already clear. That article you sent certainly makes it no less clear.

Although, I do find the below deliciously ironic:

Finally, there’s the lower class. The problem here is social breakdown. Something like a quarter to a third of American children are living with one or no parents, in chaotic neighborhoods with failing schools.

Many of these children have navigated the most treacherous of social environments. Abuse at home, gangs in the neighborhood, and no teaching at school. You'd think they'd be the intellectual highlights of our country. They're not, because everyone really knows that this is not sufficient, nor effective.

This article by Brooks is really saying two things, and is largely unrelated to his later article:

1) The free market doesn't work. People should forego higher paying jobs and do jobs that better help the country. Almost like a large-scale self-imposed socialism.

2) Businesses can't be bothered to train people that don't have college degrees. There are millions of people in the inner city that have the social skills, but not the book smarts or degrees.

Brooks's should put his money where his mouth is and implore businesses to swoop into Watts and hire the available talent. He won't though, because he doesn't actually believe that this is where the intellectual horsepower is. He thinks its at Harvard and MIT, but he'd like you to believe its in Smalltown USA.


From a couple of posts up: He's certainly part of the conservative right.

You believe this because he makes claims like this: The free market doesn't work. People should forego higher paying jobs and do jobs that better help the country. Almost like a large-scale self-imposed socialism.

So basically, Brooks is part of the conservative right because he is more or less pushing one of Obama's policy proposals [1]?

[1] They might disagree on whether it should be self imposed or government imposed. http://www.barackobama.com/pdf/NationalServicePlanFactSheet....


Those two points I give are meant to show the inconsistency in his arguments. One showing how he side steps free markets to argue against even a whiff of intellectualism.

Yet at the same time isn't willing to ask businesses to step up to the plate.

In other words, he's all about the subtext. He doesn't really believe that traditional measures of achievement are coginitively less demanding than 14 year old sleepovers, but he'll say that so that you value it less.

He doesn't actually believe in self-selected socialism (he loves free markets), but he'll attack Harvard grads so you value them less.


his position is [...] that social skills are not skills that can be learned through formal education.

How would we know? I am not aware of any mass formal education system, state supported or otherwise, that makes more than a very token nod in this direction. The closest analogue I'm aware of is social skills training for people with autism spectrum disorders. I know that works if the participants apply the theory outside the classroom, I've seen it. Hell, it even helps a little if you don't, because your modelling skills get better once you have some idea what's going on.


A lot of what etiquette schools teach is exactly that. So are most "job training" programs in the US ("don't smell bad, don't insult your interviewers, etc." - it's really a big joke; I recommend Lafer's The Job Training Charade if you want to understand what's going to happen to the US work force and economy in the next 20 years).

Your example of skills training for autism is probably the best. There's also the self-help and pick-up/dating coach industries. Every single corporate team-building workshop. Basically all of psychology.

Social skills can certainly be taught through formal education (and programmed into robots, too). They do need to be practiced also, but claiming they're not like other kinds of information is the same baseless anthropocentrism argument the conservatives keep pulling out to deny that people weren't like apes, evolution didn't happen, god exists etc. etc.


Everything is hard on a world-class level. Even programming and Math is hard on a world-class level. Writing 3D engines like John Carmack does is hard. Solving million dollar math problems, or coming up with unexpected theories is very-very hard. Creating a natural language translation system, a speech recognition system is hard. Winning the Netflix prize is hard. Programming the same kind of relatively simple webapp over and over again is probably easy; and I agree that compared to that understanding what the customer wants is usually much harder.


Yes. Writing one line of code that works is easy. Anyone can do it.

Writing two lines of code that works is also easy. Anyone can do it.

Writing ten thousands lines of codes, however, is complex and hard. A good software developer can manage, or tame, this complexity.

Programming is deceivingly simple. That's what makes it so hard.


By induction, your first line says that writing ten thousand lines of code that work individually is easy. I accept that getting them to work together is the hard part.


No. If the inductive step is that n lines of code is n! difficulty his base cases are still valid.

There is no induction with no inductive hypothesis.


You write one line of code, say "printf("Hello, World!");" ten thousand times. It's easy. Making it work together introduces the complexity.


Induction doesn't actually hold like that when you start applying things that require finite resources, such as time. Is it easy for me to find a dollar? Sure, I could get it any number of ways. It's slightly more difficult for me to $10,000. Now apply "induction" to amounts > $100,000,000.


The way you put it really reminded me of the sorites paradox.


Your customer tells you: "Yeah, the game is really fun, but a bit slow. It should run smoothly for the player, even though the internet connection is unreliable."

A well-defined problem. But which one was hard: Stating or solving it?

The attempt of artificially separating the "crafting skill" programming from the rest of software development (which is blurry enough) is an ongoing effort since decades, and still annoying.


I would not say that that's a well-defined problem. What does "run smoothly" mean? Do you mean frame rate? Do you mean lack of discontinuous motion of objects in the game? What does "unreliable connection" mean? How unreliable do you want to allow the connection to be and still have acceptable behavior? Are we talking about surviving continuous packet loss or about short-ish, bounded periods of no connection?


      I have always been puzzled by people who say that 
      math is hard. In my opinion, your understanding of most 
      math that you need is directly proportional to the effort 
      you put in, and less to do with your intelligence
Some people have a natural gift for math and can simply learn it on-the-fly.

Other people simply hate math, and as an analogy ... if something tastes like shit to you, you'll never be able to eat as much as someone who loves eating "math" AND you'll probably regurgitate whatever you force yourself to eat.

This also dismisses the research done on the ways our brain works: some people think more with the left-side of their brain, which translates in better logical / rational / analytical / objective thinking, all traits that help at doing math. And other people are downright unable to think with their left brains, further than basic functioning.

Also, consider how theorem-proving or problem-solving works: you've got knowledge of a set of theories you've learned thus far (that set can get pretty big btw) and the possibilities of combining those theories are increasing exponentially. This actually requires raw brain power (well, unless we're talking of applying really basic algorithms, like solving an ecuation of a known type, but that's not math).

When speaking of math / computer-science / programming / whatever, I actually saw people sucking at it no matter how hard they tried.


There's always that one guy at every job who talks about "high-level" "software engineering" topics but can't code for crap. It's so common I suspect causation. The idea that identifying problems is more difficult than solving them is as facile as suggesting play dates between children is more difficult than Beethoven.


You're looking at it as one or the other, when it should be one or both.

Identifying problems that are soluble and then solving them without creating too many new problems is a lot more difficult than just solving problems. And also a lot more difficult than just wandering around pointing out problems.


You're right about the people who always talk about the "high-level" topics and can't code for crap, but I also think that identifying problems is more difficult. Case in point: 42. Who knows how this number was processed?

Programming and debugging with existing code is challenging, and it's easier to talk about common ideals than actual solutions.


Programing IS hard.

You define the problem, but how do you solve it? Especially if you already have some code you have to work with.


How about, "in comparison to software development, 'programming' is easy"?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: