Programmers trying to talk to non-programmers without getting sidetracked by trivialities? IMPOSSIBLE!



  • This thread on StraightDope.

    Grumble, grumble. It's like a thread full of Cassidys. (Thought thankfully, no Bridget99s.)



  • Wow. Lot's of dumbasses in that thread, too. I like the one who tries to read all programming as if it is BASIC, or the people making some ridiculous argument that "there is no  reason to think that a=b assigns a value to a, because some language that nobody uses might do it the other way".

     

    I stopped reading about the time where people started arguing that statically typed is not the same as strongly typed... as if anybody gives a fuck.



  • I don't see the worsethanfailure. The discussion is an intelligent one about basic programming theory. It's trivial only superficially. People dying because of programming errors and how that affected language design is not trivial.

    You do have a funny avatar though, so there's that.



  •  @Jonathan said:

    I don't see the worsethanfailure. The discussion is an intelligent one about basic programming theory. It's trivial only superficially. People dying because of programming errors and how that affected language design is not trivial.

    You do have a funny avatar though, so there's that.

     

    1. Person asks "what is the answer to this basic question, and can somebody explain how that answer is reached.

    2. Some people answer that question

    3.Other people dickweed around the meaning, saying that the semantics and language  aren't known so it's not a good idea to make assumptions

    4.other people get involved, suddenly they start talking about bugs and programming errors, then somebody latches onto somebody else using the term "Strongly-typed" and argues that what they obviously meant was statically typed, which is apparently not only completely different but in some way relevant to the topic.

     

    Now, imagine this happened on a math forum. THe person would ask the steps to solve 12(23-4x)=45

    Some people would solve it. And then some dickweeds would jump in and declare that there was no way to solve it, because it doesn't say what number base it uses, and others ramble on about how without saying wether the numbers in question were part of the real number set or merely integers it was impossible to solve the problem. Meanwhile, the people with brains long left the topic. That's pretty much the same story we have here.

     

     

    The first post asks the answer to a question about this code:

    int a = 10;

    int b = 20;

    a = b;

    Specifically, what a and b are at the end of it.

     

    the WTF is that we have replies like this:

    "That one-line string copy is an abomination of structured programming
    because it does exactly what structured program is NOT supposed to do --
    or, from another point of view, it does exactly what that kind of while
    ( ) loop is specifically designed NOT to do. "

     

    "Perl actually has different operators for numeric and string types
    (numeric uses the conventional C-like operators, strings use
    "alphabetic" operators like eq, le, gt, etc.). Some examples:"

     "Is this really the same phenomenon, though? Scheme, for instance, has a
    "numeric tower", because all integers are rationals are reals are
    complex. But there's just no way to add a string to an integer without a
    function that does this explicitly."

    Including some posts about why Dennis Ritchie only believed in compilers that could compile Duff's Device, and some other pointless crap. As if compilers are around for fucking parlour tricks or something. Either way, everything past about the first half-dozen replies has pretty much nothing to do with the original post.

     


  • Winner of the 2016 Presidential Election

    @BC_Programmer said:

    Either way, everything past about the first half-dozen replies has pretty much nothing to do with the original post.

    It's a good thing that never happens here.



  • @Jonathan said:

    I don't see the worsethanfailure. The discussion is an intelligent one about basic programming theory. It's trivial only superficially. People dying because of programming errors and how that affected language design is not trivial.

    What's your StraightDope forum account name?



  • @joe.edwards said:

    @BC_Programmer said:
    Either way, everything past about the first half-dozen replies has pretty much nothing to do with the original post.

    It's a good thing that never happens here.

     

     

    CAUSE:

    "This behaviour is by design"

     

    Come to think of it it might be the status quo there, too. Though I don't think I've ever seen a thread devolve here to the point of talking about C trivia and Duff's devices. 

     



  • @BC_Programmer said:

    3.Other people dickweed around the meaning, saying that the semantics and language  aren't known so it's not a good idea to make assumptions

    I like how barely anyone actually realised that this was the entire point of the original question - to see what assumptions people made, and if they were consistent about it.



  • @BC_Programmer said:

    I stopped reading about the time where people started arguing that statically typed is not the same as strongly typed... as if anybody gives a fuck.
    Perhaps someone should introduce Fizz-Buzz to the SD message board...?



  • @blakeyrat said:

    What's your StraightDope forum account name?
     

    touché!



  • @BC_Programmer said:

    ...

    1. Person asks "what is the answer to this basic question, and can somebody explain how that answer is reached.

    2. Some people answer that question

    3.Other people dickweed around the meaning, saying that the semantics and language  aren't known so it's not a good idea to make assumptions

    4.other people get involved, suddenly they start talking about bugs and programming errors, then somebody latches onto somebody else using the term "Strongly-typed" and argues that what they obviously meant was statically typed, which is apparently not only completely different but in some way relevant to the topic.

    ...
    Are you talking about "conversations" on this forum???



  • @BC_Programmer said:

    Wow. Lot's of dumbasses in that thread, too. I like the one who tries to read all programming as if it is BASIC, or the people making some ridiculous argument that "there is no  reason to think that a=b assigns a value to a, because some language that nobody uses might do it the other way".
     

    The question is one used in a test to investigate the question whether some people "can" program while others "cannot".

    In that context, any basic assumptions about the inner workings of the hypothetical language in the question as compared to existing languages are unwarranted.

    Specifically, to someone who's never known about any programming, the statement "a = b"  might be a question, to which the answer is "nope, they're not equal." and then nothing happens.

    And that's how the cookie crumbles.



  • @blakeyrat said:

    This thread on StraightDope.

    Grumble, grumble. It's like a thread full of Cassidys. (Thought thankfully, no Bridget99s.)


    Is the WTF the conclusion of the Coding Horror article (as was referenced in the first Straight Dope post) ie. that programming concepts as simple what a variable is and assignment are "literally unteachable to a sizable subset of incoming computer science students" ? (based on an "acedemic paper" that "reads like a blog entry" and suggests that half a class failing a very basic test on variables and assignment 3 weeks into an introduction to programming course is due to the half of the class that failed being "unteachable").

     

    Hmm could the issue be explained by:

    • Failure of instruction? Surely not! The students were taught by professional university lecturers
    • Inability to learn the syntax? Presumably the students could learn other syntax (eg. basic algebra) hmm... guess that can't be it
    • Inability to understand the concept? Wasn't either of the above, ipso facto this must be the explanation

    Except, as a concept it's hardly a challenge...

    A waitress asks what you and your friend will be drinking, you order a beer and your friend orders a double scotch on the rocks, you think "that sounds good" and tell the waitress to change your order to "what he's having".

    Am I to believe that half of all computer science students couldn't figure out what two drinks should be sent to the table in problem above (I think it is conceptually similar to the example 3 line problem given)?



  • @BC_Programmer said:

    3.Other people dickweed around the meaning, saying that the semantics and language  aren't known so it's not a good idea to make assumptions

     

    I don't see anything "dickweedish" about that.  After getting the straightforward answer out of the way, people in the forum used it as a launching point to get into deeper discussion of the philosophy of computer language syntax and structure.  That's how geeks are, and it's odd to attack this attribute on another geek forum like this.

     



  • So TRWTF are the aspies who can't cope when a discussion doesn't stay focused on the original topic?



  • Who the fuck are you and why do you have so may forum posts?



  • @BC_Programmer said:

    1. Person asks "what is the answer to this basic question, and can somebody explain how that answer is reached.

    2. Some people answer that question

    3.Other people dickweed around the meaning, saying that the semantics and language  aren't known so it's not a good idea to make assumptions

    4.other people get involved, suddenly they start talking about bugs and programming errors, then somebody latches onto somebody else using the term "Strongly-typed" and argues that what they obviously meant was statically typed, which is apparently not only completely different but in some way relevant to the topic.

    So, one person asks a very simple question, someone else provides a full answer in the next post, the person who asked the question acknowledges the answer. Then, instead of locking the thread as would have been sensible, people kept posting progressively unrelated things? How horrifying!



  • @BC_Programmer said:

    some ridiculous argument that "there is no  reason to think that a=b assigns a value to a, because some language that nobody uses might do it the other way"

    I always thought that using the equal sign for assignment is bound to cause confusion. The equal sign is supposed to denote equality, which is directionless. Confronted with the equality in the realm of programming for the first time, I would probably interpret it as "bind a to b", in such a way that the two variables are now aliases of each other. Another interpretation is the one that dhromed mentioned, that it is a question. A third would be that b gets assigned the value of a, as others have pointed out. I'm sure that there's more. Anyway, I'm surprised that directional symbols aren't more prominent, like the arrows used by Knuth (and OCaml, APL, R).



  • @Obfuscator said:

    @BC_Programmer said:

    some ridiculous argument that "there is no  reason to think that a=b assigns a value to a, because some language that nobody uses might do it the other way"

    I always thought that using the equal sign for assignment is bound to cause confusion.

    That's why the great Niklaus Wirth designed Pascal with := as the assignment statement and = as the conditional test.



  • @nat42 said:

    A waitress asks what you and your friend will be drinking, you order a beer and your friend orders a double scotch on the rocks, you think "that sounds good" and tell the waitress to change your order to "what he's having".

    Am I to believe that half of all computer science students couldn't figure out what two drinks should be sent to the table in problem above [...]?

    Obviously, that will be a beer, a double scotch on the rocks, and a double scotch on the rocks (counting from 0 of course).



  •  On the other hand, it takes 4 secons flat explain to a novice that a = b puts the value of b into a, so it's not like there's an actual problem.



  • @nat42 said:

    A waitress asks what you and your friend will be drinking, you order a beer and your friend orders a double scotch on the rocks, you think "that sounds good" and tell the waitress to change your order to "what he's having".
     

    Before the jokes: good example. Nicely done.

    Now: What if after you have what he's having, your friend changes his mind and orders a rum cooler with an umbrella? What do you get then? What if you're pointing at him when you say it, and keep pointing at him?

    Now there's someone at the next table who likes you and your friend's drink ordering style, so she points at you for her drink order. What does she get? 

    Then you all decide to go to a different bar. How can you tell if the ever-so-slightly different waitress will treat your "I'm having what he's having" paradigm the same way?




  • @BC_Programmer said:

    I stopped reading about the time where people started arguing that statically typed is not the same as strongly typed... as if anybody gives a fuck.

     

    +1.

    I had to withdraw from a discussion about the use of var in C# for this very reason (and my own sanity). Some people are just too clever to believe the manufacturer's documentation and automatically know better, despite all evidence being to the contrary.

     



  • @Lorne Kates said:

    What if you're pointing at him when you say it, and keep pointing at him?
     

    What if he gets up and leaves while you point at him, and in the mean time someone else sits down in his chair?



  • @dhromed said:

    @Lorne Kates said:

    What if you're pointing at him when you say it, and keep pointing at him?
     

    What if he gets up and leaves while you point at him, and in the mean time someone else sits down in his chair?

    That indicates that he's sick of you pointing at him like an idiot and doesn't want to drink with you anymore.



  • For what it's worth, in Prolog, A=B can assign in either direction (depending on which of A or B has a value; if neither has a value, it'll remember that the assignment needs doing in the future and do it when one of them gets a value; if both have a value, it fails unless the values happen to be the same, which is like throwing an exception except you're allowed to do it for control flow). Prolog does this sort of thing for everything (except arithmetic), so it's not really out of place there. (OK, and for pedants, it's not quite the same operation as assignment, but it's pretty close to (single static) assignment.) And in many languages, = is an equality test not an assignment.



  • @dhromed said:

    @Lorne Kates said:

    What if you're pointing at him when you say it, and keep pointing at him?
     

    What if he gets up and leaves while you point at him, and in the mean time someone else sits down in his chair?

     

    What if no one sits down in his chair, and the waitress just stares glassy-eyed until she goes into a panic, has an aneurysm, dumps a log onto the floor, and dies?

     



  • @JimLahey said:

    @BC_Programmer said:

    I stopped reading about the time where people started arguing that statically typed is not the same as strongly typed... as if anybody gives a fuck.

     

    +1.

    I had to withdraw from a discussion about the use of var in C# for this very reason (and my own sanity). Some people are just too clever to believe the manufacturer's documentation and automatically know better, despite all evidence being to the contrary.

     

    I have to cancel your +1 with a -1 because of Python Vs. VBScript.



  • @Lorne Kates said:

    @dhromed said:
    @Lorne Kates said:
    What if you're pointing at him when you say it, and keep pointing at him?
    What if he gets up and leaves while you point at him, and in the mean time someone else sits down in his chair?
    What if no one sits down in his chair, and the waitress just stares glassy-eyed until she goes into a panic, has an aneurysm, dumps a log onto the floor, and dies?

    Of if your friend is actually a figment of your imagination and never existed, and the waitress follows your finger out the door to see what you're pointing at, but she's wearing a shock collar, and the invisible fence around the door sets it off, and she suddenly drops to her knees foaming at the mouth screaming "NULL POINTER EXCEPTIOONN!! AAAAURHHGHADSKLFJLSKJFOSDJFLDSKFLKE"     ..?



  • @ais523 said:

    For what it's worth, in Prolog, A=B can assign in either direction (depending on which of A or B has a value; if neither has a value, it'll remember that the assignment needs doing in the future and do it when one of them gets a value; if both have a value, it fails unless the values happen to be the same, which is like throwing an exception except you're allowed to do it for control flow). Prolog does this sort of thing for everything (except arithmetic), so it's not really out of place there. (OK, and for pedants, it's not quite the same operation as assignment, but it's pretty close to (single static) assignment.) And in many languages, = is an equality test not an assignment.
    WFT? Did you follow blakey back here from that thread?



  • @Xyro said:

    Of if your friend is actually a figment of your imagination and never existed, and the waitress follows your finger out the door to see what you're pointing at, but she's wearing a shock collar, and the invisible fence around the door sets it off, and she suddenly drops to her knees foaming at the mouth screaming "NULL POINTER EXCEPTIOONN!! AAAAURHHGHADSKLFJLSKJFOSDJFLDSKFLKE"     ..?
     

    Ooh!  Dinner theatre!



  • Salamander pointed this out, but did not fully go into it so it appears to have been over looked, so here it is...

    The whole point of the research was not whether someone knew what a=b meant, but if someone could form a possible logical meaning for it and then apply that same logic across a whole test worth of similar problems.  So there was no 'right' answer for any given problem, but if they were consistent, inconsistent, or did not care when they tried to answer it.  The writer of the original paper claimed that it was only those who could apply logical rules consistently could learn how to program.  Which if you think about makes some sense, if you see a=b and think copy left assignment, and then later on the same test decide that b=a means copy right assignment then you probably should change your major.  I personally think anyone -can- be taught basic programming logic, but that it is not likely a good idea for far too many reasons.  Just imagine someone writing code and in their head the meaning of different logical operations is changing based off what they feel it should mean given the context, think about the quality of the code they are going to be creating and the likelihood that it will end up here.



  •  @some_idiot_on_other_forum said:

    I totally agree with TriPolar. I've been programming in BASIC since the late 70s, and was totally thrown by the syntax of the OP's example.

    TRWTF right there. This dude has been programming BASIC for over 30 years and still can't read other languages. Someone buy him this.

    Actually, wait. TRWTF is simpler - he's been programming BASIC over 30 years.

     



  • @Anketam said:

    The writer of the original paper claimed that it was only those who
    could apply logical rules consistently could learn how to program. 
    Which if you think about makes some sense, if you see a=b and think copy
    left assignment, and then later on the same test decide that b=a means
    copy right assignment then you probably should change your major.
     

    Forming a hypothesis (because that's what it is) about a completely unkown system from a tiny speck of data is a special type of thinking that must be learned. Not everybody has it by default, and it takes more than a little time to teach someone to think in a certain way, or be confident about their own inferences. At the very least you need to have lived with the fundamental assumption that everything is (approximately) systematic and can be analyzed and understood, and again, not everybody grows up with that assumption. But it can be taught.

    It is entirely different from sitting someone down with a certain programming language and explaining that a particular syntax structure has a specific meaning. This always works.

    My basic point is that no person exists who is absolutely incapable of programming. But it may take some time, and from a practical point of view, you may elect to do something else with your life. This applies to everything anyone can do.

    It's a great joy to watch the lights go on in someone's head.



  • I think there are some people who will never 100% get pointers. I also think I'm one of them.

    All the more reason to toss out our shitty old languages from crap-town which have them.


  • Discourse touched me in a no-no place

    @blakeyrat said:

    I think there are some people who will never 100% get pointers.

    I think that's why the weed-out course I took back in the day used Lisp and assembler. C was no problem after that experience.



  • @blakeyrat said:

    I think there are some people who will never 100% get pointers. I also think I'm one of them.

    All the more reason to toss out our shitty old languages from crap-town which have them.

     

     

    One of the more amusing things i heard a friend say once was "Oh, C++? I don't get that, you know, with all the pointers and all. I just use Java. It doesn't have pointers."

    Now I'm not trying to get into a debate over which is "better" (or the perhaps pertinent point -ahem- about memory management), but all "references" in java are just pointers, right. You copy or compare them (with trival operations) and they behave like C pointers. You clone() or compare() them and they behave like objects.

    After explaining this, the friend in question now gets pointers. I don't know if he gets manual memory management, but that's another lecture.

     


Log in to reply
 

Looks like your connection to What the Daily WTF? was lost, please wait while we try to reconnect.