CapeWearingAeroplane

joined 1 year ago
[–] [email protected] 3 points 2 months ago

GET THE ROUNDIE!

[–] [email protected] 0 points 4 months ago (1 children)

The way I understand this, the issue is that without reading it they cannot verify that it doesn't contain sensitive information, so they can't give it out. That sounds like a reasonable explanation to me.

[–] [email protected] 1 points 4 months ago

The issue with online voting, no matter what you do, is that someone can force you under threat of violence to vote for a specific candidate, and watch to make sure you do it. Complete privacy in the voting booth is paramount to ensuring that everyone can vote freely.

[–] [email protected] 2 points 5 months ago

Oh, I definitely get that the major appeal of excel is a close to non-existent barrier to entry. I mean, an elementary school kid can learn the basics(1) of using excel within a day. And yes, there are definitely programs out there that have excel as their only interface :/ I was really referring to the case where you have the option to do something "from scratch", i.e. not relying on previously developed programs in the excel sheet.

(1) I'm aware that you can do complex stuff in excel, the point is that the barrier to entry is ridiculously low, which is a compliment.

[–] [email protected] 3 points 5 months ago (2 children)

I just cannot imagine any task you can do in excel that isn't easier to do with Python/Pandas. The simplest manipulations of an excel sheet pretty much require you to chain an ungodly list of arcane commands that are completely unreadable, and god forbid you need to work with data from several workbooks at the same time...

[–] [email protected] 5 points 5 months ago (1 children)

You are neglecting the cost-benefit of temporarily jumping to the wrong conclusion while waiting for more conclusive evidence though. Not doing anything because evidence that this is bad is too thin, and being wrong, can have severe long-term consequences. Restricting tiktok and later finding out that it has no detrimental effects has essentially zero negative consequences. We have a word for this principle in my native language - that if you are in doubt about whether something can have severe negative consequences, you are cautious about it until you can conclude with relative certainty that it is safe, rather than the other way around, which would be what you are suggesting: Treating something as safe until you have conclusive evidence that it is not, at which point a lot of damage may already be done.

[–] [email protected] 4 points 5 months ago (3 children)

So what you're saying is: We have a small sample of unreliable evidence that this thing may be absolutely detrimental to the developing brain. Thus, we should assume it's fine until we have more reliable evidence. Did I get that right?

[–] [email protected] 1 points 5 months ago

I am very fond of the idea of "stateless" code, which may seem strange coming from a person that likes OOP. When I say "stateless", I am really referring to the fact that no class method should ever have any side-effect. Either it is an explicit set method, or it shouldn't affect the output from other methods of the object. Objects should be used as convenient ways of storing/manipulating data in predictable/readable ways.

I've seen way too much code where a class has methods which will only work"as expected" if certain other methods have been called first.

[–] [email protected] 3 points 5 months ago (1 children)

Sounds reasonable to me: With what I've written I don't think I've ever been in a situation like the one you describe, with an algorithm split over several classes. I feel like a major point of OOP is that I can package the data and the methods that operate on it, in a single encapsulated package.

Whenever I've written in C, I've just ended up passing a bunch of structs and function pointers around, basically ending up doing "C with classes" all over again..

[–] [email protected] 7 points 5 months ago (1 children)

I would argue that there are very definitely cases where operator overloading can make code more clear: Specifically when you are working with some custom data type for which different mathematical operations are well defined.

[–] [email protected] 2 points 5 months ago (1 children)

This makes sense to me, thanks! I primarily use Python, C++ and some Fortran, so my typical programs / libraries aren't really "pure" OOP in that sense.

What I write is mostly various mathematical models, so as a rule of thumb, I'll write a class to represent some model, which holds the model parameters and methods to operate on them. If I write generic functions (root solver, integration algorithm, etc.) those won't be classes, because why would they be?

It sounds to me like the issue here arises more from an "everything is a nail" type of problem than anything else.

[–] [email protected] 4 points 5 months ago

Oh, thanks then! I've heard people shred on OOP regularly, saying that it's full of foot-canons, and while I've never understood where they're coming from, I definitely agree that there are tasks that are best solved with a functional approach.

view more: next ›