Live data from Hacker News

Ask HN: Concepts that clicked only years after you first encountered them?

news.ycombinator.com

131–140 of 946 posts

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#131

Earlier quoted context omitted.

>In particular the "social democracy" strains of socialism as opposed to those advocating central planning or anarchist organization. Yes; Most people get hung up on terminology and/or specific interpretations but i am convinced this is the natural order of things for the Human species. The balance without going to extremes is what is important.

> Most people get hung up on terminology and/or specific interpretations Because terminology matters, and some terms are quite misleading. What some people tend to miss about the "Socialism with Scandinavian Characteristics" that folks claim to like these days is that Scandinavian countries are actually near the very top rankings by economic freedom and lack of excess regulatory burden. I.e. they're actually some of…

I’ve thought for years that the ideal would be a very free market with very little regulation combined with a basic income and a strong social safety net.

Let people go wild and try stuff and do whatever but raise the floor up to the point where people can recover from failure and where the less fortunate are not suffering.

This kind of “social capitalism” could be freer and less regulated than what we have now.

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#132

Matrix multiplication. First encountered it in high school, where the textbooks presented matrices without any real motivation, and matrix multiplication just seemed like a weirdly-defined operation. Once I got to linear algebra in college and matrix multiplication was presented as the way to compose linear transformations, it made a lot more sense.

It took me taking a class in neural networks in my thirties to really understand matrix multiplication

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#133

Earlier quoted context omitted.

Not sure about poster above, but I found a large amount of value in writing tests when developing API backends. I knew the shapes and potential data. Was easier to write tests to confirm endpoints looked right than manually hit the api endpoints.

Always amuses me when I see tests spin up a http server, just to call a function.

It used to be hard. I just spent a day in c# and gql figuring out how to do API level tests with a new framework. But when you get it working it's ever so much faster.

https://github.com/gaffo/CSharpHotChocolateZeroQLIntegration...

Still playing around with the right level for this but this is currently nice as it gives me compiled type checking and refactoring. This is an example/extraction from another project which uses react as the client. Wasn't big on cross language api level tests yet for speed of development, as that's a tradeoff. Redundancy vs even more framework.

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#134
post #5

Discrete mathematics and all sorts of its application in real-world (software development) related problems. Also how any given solution to a problem in one problem domain can be transferred to a problem in another unrelated domain. Think Galois theory but waaaay less fancy :-)

When I did Mathematics A-Level's, we had to select four modules. I chose pure 1, pure 2, stats 1 and, new that year, discrete 1.

So many useful groundings in various super important comp sci concepts.

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#135
programming in general, i tried probably half a dozen different times throughout my early teens to understand how to write programs in pascal, C, python, java, and it wasn't until I was 18 when I found Zed Shaw's "Learn Python the Hard Way" that it clicked.

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#136

Earlier quoted context omitted.

Getting rid of data abstraction and encapsulation is throwing the baby with the bath water. The abstract concept of OOP (messages between complex objects, as defined by Alan Kay) is an attempt at mimicking biological systems. Most modern languages implement data abstraction, but call it OOP, where they encapsulate some functionality with the data it operates on. Really helped with varying data formats in the AirForce…

I believe that combining state and functionality - the root of OOP - is a mistake. Tons of programming patterns and concepts exist to solve this fundamental mistake. When you stop using classes all of your code becomes so much cleaner, easier to reason about, test, debug, and so on. You can never create only pure functions in the real world but you get closer to this ideal. I stand by my statement that OOP is totally…

You can believe that the world is flat, announce that boldly and stand by your statement. It doesn't mean it's true in reality, only that it's true in your mind.

Edit: This is more blunt than I intended it to be. For what it's worth, I happen to agree with you in principle, but I also think you're taking the roof off the car here and boldly claiming that the experience is so much better in the summer. What about winter? What about when it rains? What are the trade-offs? Not mentioning the downsides means that you either haven't found them, haven't thought about them or are intentionally omitting them from the discussion.

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#137

Working with others. Really. I was super annoyed and insanely annoying to work with for years. Then I understood that difference is hard to cope with, but more often than not, good. As it trades some short term efficiency to long term one. Same with your output. If it is dumbed down to a level everyone can understand it, you really learned it.

That’s cool, what kinds of things helped you learn this? I bet those things would be really valuable to a lot of people if you felt like sharing.

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#139

Earlier quoted context omitted.

Seven years into my career I'm increasingly convinced that the emperor has no clothes with respect to unit tests that are just transcripts of the code under test with "mock.EXPECT()" prepended to everything - 95% by volume of the unit test code I've ever read, written, or maintained.

Yep, I think mocks are mostly a smell. The "functional core" of a module should be entirely or almost entirely unit testable with (possibly fake) dependencies passed in. The glue code ("imperative shell") should be tested at a higher level - "integration" or "end to end" or whatever you want to call it - which looks at the externally observable effects of running the code (database changes or API responses or whateve…

How are mocks a smell if "unit testable with (possibly fake) dependencies" is okay? That's what mocks are.

Or do you mean specifically "expecting" interactions with those mocks? Because I agree that's usually not that valuable.

Re: Ask HN: Concepts that clicked only years after you first encountered them?

#140
YAGNI and KISS.

When I was a junior developer I used to overthink and overdesign solutions, most of which was never needed. It took many years and a lot of battle scars to realize that less abstraction is more. Today I see a lot of juniors do the same mistake and I ask them to revise their designs to keep it simple.

Post reply on HN