5 ms·
>You have missed the point. Tell me what you think the point is. Typically when someone thinks a point was missed they address the point rather than devolve th
by leafboi 6y ago
>You have missed the point.
Tell me what you think the point is. Typically when someone thinks a point was missed they address the point rather than devolve the conversation into a condescending description about my character and how I should act. It's a sort of tactical what you're doing here. But who cares, no one is reading.
It's curious how you don't even address my points and just say that I missed the point when I'm the one dictating the point in my original comment. Typically this isn't how you respect other people and get them to respond positively to your comments, what you're doing will draw other people to support you but anger your target because of the condescension. I'm not sure what you're objective is because people aren't really reading this thread... it's already buried.
>It’s curious you think this piece is written by a “JavaScript programmer”,
The examples in the original piece are in javascript. Why don't you RTFA before commenting on the "point."
>and the person who responded to you here is a “junior” — the implication being that you know more.
The Junior thing was more of a retort. I said it with full awareness of what it implies and how the other person would take it because his tone obviously implies that he doesn't think he's a junior. Basically the replier has his own opinion which he is entitled to say (and that I respect) but when you say things like "dogmatic" and then vote me down... that's just not respectful. Since I can't vote him down I inject a bit of subtle rudeness in my replies as a subtle retort in return. Just being a mirror. Similar in a way to the subtle game you're playing. That's all this is.
>It might help to take a step back and assume intelligence in others: what if these people are smart? What could you learn from them? If you think the idea is wrong, assume it’s coming from a peer. One way you know you are doing that, is if you form your disagreement as a question.
Maybe you should take a step back and look at your own post. Telling people to shift their thinking implies you have a sort of superiority complex. As if you're not the one that's mistaken. How do you know I'm not a peer? How do you know I'm not superior. Perhaps you should take a look at yourself. You seem like a guy who thinks he's superior to me in programming but you haven't demonstrated as much, you haven't even addressed the point.
You went on a side tangent talking about my behavior. Trust me, if you want someone to change or listen to you, talking to them like this is not the path.
You want to know what will make people respond to you and listen to you? Address them without any subtle disrespect. It's very simple.
You could've responded to me like this:
I disagree with you. I also think there was a misunderstanding of the point. Here's why...
By proving the other person wrong without being disrespectful you can change the other person's' character. But obviously this isn't our objective here is it?
That being said take a look at this wikipedia post and tell me. Who missed the point?
https://www.wikiwand.com/en/Functional_programming https://www.wikiwand.com/en/Functional_programming
"Functional programming is sometimes treated as synonymous with purely functional programming, a subset of functional programming which treats all functions as deterministic mathematical functions, or pure functions. When a pure function is called with some given arguments, it will always return the same result, and cannot be affected by any mutable state or other side effects. This is in contrast with impure procedures, common in imperative programming, which can have side effects (such as modifying the program's state or taking input from a user). Proponents of purely functional programming claim that by restricting side effects, programs can have fewer bugs, be easier to debug and test, and be more suited to formal verification.[1][2]"
Literally that's the definition I'm following. It's one form of the definition and certainly a popular one. That's my opinion. You disagree? You think I missed the point? Elucidate. The original poster can disagree but my opinion is far from as he puts it "absurd."
Read the article. What definition of functional programming does that class with a setter even fit under? Ok he redefined it as a higher order function... Is what he doing procedural programming or functional programming. It looks to me he's doing a bit of everything and calling it a function. Does the guy even know that the class keyword is just sugar for "function" in javascript?
Look at this: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Classes https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
Literally it says "classes" are just special functions. He's just reiterating the javascript spec as if it's a new fangled discovery. In fact, before ES6 all "classes" were written with the keyword "function." No dude. The article writer doesn't get it and neither does the person who responded to my post. When you do OOP with LISP you're not doing FP period. The article writer just noticed an isomorphism and is likely amazed by what all JS programmers were doing before ES6. Not to be insulting but the parent poster likely doesn't have much experience.
>I took the time to respond to you, because it looks like you have some real love for programming, but know less than you think. You can grow a lot more if you shift some of your thinking
I too took the time to respond to you. Despite your condescending attitude/game. Let's see where this goes.
- stopachka 6y ago> It's curious how you don't even address my points and just say that I missed the point when I'm the one dictating the point in my original comment. > Typically this isn't how you respect other people and get them to respond positively to your comments > The examples in the original piece are in javascript. Why don't you RTFA before commenting on the "point." I wrote that article, so in effect you are responding to my original comment : ). Fair that what I wrote was condescending. I purposefully wrote it that way, as a second meta-point: to get you to experience what it feels like when people assume negative, and use words like "Ok, no", "Javascript programmer" (negative connotation), "junior" With that accomplished, moving on to more civil ground. > I'm not sure what you're objective is because people aren't really reading this thread... it's already buried. First, as you can now feel, I was pretty annoyed by your presumptuous tone in your initial comment. Second it really did feel like you had depth and love in programming, but from your comments I intuited some traits that lead to lower potential outcomes. Mainly: jumping to conclusions too quickly (harder to learn new things this way, and unless you are almost finished with your career, it can be detrimental). > Does the guy even know that the class keyword is just sugar for "function" in javascript? ... Not to be insulting but the parent poster likely doesn't have much experience. Yes, I do know what classes de-sugar to in javascript, I worked with many of the folks who brought classes to the ES spec. As you most likely know, javascript classes are a bit of a special case, because JS uses prototypical inheritance. Classes in other languages do not de-sugar this way. For example: you can see a function as a special `class` with only one method `apply`, or you could see a class as a special higher order function. > Who missed the point? The point is, that though functions and classes seem distinct, they are less distinct than one would think. In your comments, you seem very attached to the specific distinctions you've set up with classes, procedures, and functions. One question I would ask you is: what is _similar_ about them? Could you express all of these with one abstraction? Is there a difference between choosing `class` as the base abstraction, vs a closure?
- leafboi 6y ago>One question I would ask you is: what is _similar_ about them? Could you express all of these with one abstraction? Is there a difference between choosing `class` as the base abstraction, vs a closure? The answer is yes you can. But you're thinking in the wrong direction. First let's make things clear. A function is just a one line expression where all values are immutable. There is no concept of time or procedures in a function. function def f(x): return ((x + 1) * 2)/3 procedure: def f(x): x = x + 1 x = x * 2 x = x / 3 return x You are saying that a procedure is isomorphic to an object which is to say you can define an object in terms of a procedure and a procedure in terms of an object. People often mix up the two terms, procedure and function but it's no big deal. The issue is, you used the term "Higher Order" function and the second issue I had was that it's actually quite an obvious thing presented as if it was novel. Well first off all computers are procedural machines. The underlying machine is just executing machine code which is a series of procedures. So all programming languages on top of this are implemented with procedures. That means OOP languages are implemented with procedures. That means FP languages are implemented with procedures. That means procedural languages are implemented with procedures. Basically your post is just reiterating how an object is implemented by a compiler. However the title of your post used "Higher Order Function." This implies you don't know the distinction between procedures and functions as "Higher order" functions are usually reserved for true functions, not procedures. That was the point of my post, to help you see the distinction because although you can create objects from procedures, you cannot create objects from functions because objects require mutation which is a primitive that a function cannot actually provide. The relationship is surjective or unidirectional. >harder to learn new things this way, and unless you are almost finished with your career, it can be detrimental This is the internet. I can communicate without a filter on the internet with little consequence. Filters slow things down as do a lack of filter. Either way I can get to the point quickly without worrying about offending someone.