also I just realized that Brazil did NOT make a programming language entirely in Spanish and call it “Si” and that my professor was making a joke about C… god damn it
this post is probably too nieche but I feel like Lemmy is nerdy enough that enough people will get it lol
Brazil did NOT make a programming language entirely in Spanish
Because we speak fucking portuguese
Sim
To start with Brazil speaks Portuguese not Spanish
C is too cold. Python is too hot. What is just right?
Nim. Python-esque way to write, C speed
Visual Basic.
I’ll be honest, I think modern python is cool. You just need to accept that it has some limitations by design, but they mostly makes sense for its purpose.
It’s true that the type system is optional, but it gets more and more expressive with every version, it’s honestly quite cool. I wish Pylance were a bit smarter though, it sometimes fails to infer sum types in if-else statements.
After a couple large-ish personal projects I have concluded that the problem of python isn’t the language, but the users.
On the other hand, C’s design is barren. Sure, it works, it does the thing, it gives you very low level control. But there is nothing of note in the design, if not some quirks of the specifications. Being devoid of innovation is its strength and weakness.
As someone who studied C exclusively in school and used it for the majority of programming projects I had in the real world, coming to Python now is like moving from a kit car like a Caterham to a Mercedes S class.
Knowing nothing about code but a fair bit about cars, does that analogy mean like, you can play around with a kit car all you want because you built it, it’s relatively simple, and if you break it you’ll know why and how to fix it, and the Mercedes being the exact opposite?
C does one thing really well and that’s everything fast with complete control. Python is cool for people just trying to bang out some scripts or learning to program but interpreted languages have no place in mainstream software. Devices are starting to become slower than computers 30 years ago because there is so much garbage being included in apps written in interpreted java and Python and other nonsense. It’s not just bad for the user but it’s bad for the planet. It shouldn’t take a million times the energy to run a simple program because someone doesn’t know how to write in a proper language. Python is okay for some things. The world has become too reliant on it though. Also just for purely selfish reasons if you are the type. Interpreted languages kill your battery life and ram and stuff. Modern android phones besides all their problems with Google ruining them like Microsoft are also just becoming incredibly slow and stupid. You can barely even open two apps without most android phones panicking and closing apps to save memory. A calculator app is 100 MBs now. The phone feels like it’s going to catch on fire when you open a notepad.
I like many of your points, but your comment is facetious.
You said it yourself, “it’s good for someone trying to bang out scripts”… and that’s it, that’s the main point, that’s the purpose of python. I will argue over my dead body that python is a trillion times better than sh/bash/zsh/fish/bat/powershell/whatever for writing scripts in all aspects except availability and if that’s a concern, the only options are the old Unix shell and bat (even with powershell you never know if you are stuck ps 5 or can use ps 7).
I have a python script running 24/7 on a raspberry that listens on some mqtt topics and reacts accordingly asynchronously. It uses like 15kiB (literally less than 4 pages) of ram mostly for the interpreter, and it’s plenty responsive. It uses about two minutes of CPU time a day. I could have written it in rust or go, I know enough of both to do it, it would have been faster and more efficient, but it would have taken three times the time to write, and it would have been a bitch to modify, I could have done it in C and it would have been even worse. For that little extra efficiency it makes no sense.
You argue it has no place in mainstream software, but that’s not really a matter of python, more a matter of bad software engineers. Ok, cool that you recognise the issue, but I’d rather you went after the million people shipping a full browser in every GUI application, than to the guys wasting 10 kiB of your ram to run python. And even in that case, it’s not an issue of JavaScript, but an issue of bad practices.
P.S. “does one thing well” is a smokescreen to hide doing less stuff, you shouldn’t base your whole design philosophy on a quote from the 70s. That is the kind of shit SystemD hater shout, while running a display server that also manages input, opengl, a widget toolkit, remote desktop, and the entire printer stack. The more a high profile tool does, the less your janky glue code scripts need to do.
Uses less memory until it inevitably springs a memory leak. And its not a million times the memory, its ~10x. You should check out assembly language, it beats C in all the metrics you care about.
If you can eat it, then it’s edible.
Change my pythonic mind.
Why would Brazil choose Spanish?
Brazil is a known Mexican Country, obviously they speak Spanish
Ridiculous. They’re in Latin America, so they speak Latin.
Ego puto in orto meo
Cuz Brazil speaks Spanish, duh. Not every country has English as their language, dummy
good ragebait 👌
Beigerate: kinda boring, but not bad.
Don’t they talk Mexican?
Factually, no
But don’t they use Portuguese?
What’s that? There’s English, French (aka weirdo Canadian), German (aka hate speech), Spanish (aka Mexican) and China
What are you on about?
Factually, yes (though quite distinct from its European counterpart).
From the 'Murican perspective? It’s all Mexico under the US.
C is the old carpenter, who can drive in nails with three strikes of the hammer and never forgets his tools.
C# is his friend who just uses power tools instead. He is fine too. He goes home early whenever he can.
Python is the new guy at work who thinks he’s super smart. He actually can do the job really well, but for some reason nobody likes him all that much.
Javascript is the boss’s son who got the job since he agreed to stay off pills but he does not. He is useful to be friendly with, maybe, but avoid him any day that you can. Typescript is his weird fiancée. She is significantly less stupid but much more rarely useful, and also best avoided.
Go and Rust are tight-knit friends who get shit done. They are extremely capable but also not friendly, they tend not to talk much.
Clojure does mushrooms on weekends, and seems to believe he has key insights the rest of the crew is too dim to understand, but he also makes frequent simple mistakes on the job and forgets things. Also avoid.
Java only has the job because he’s known the boss since they were kids. He was never that good, but now he is old, and frequently drunk. Avoid at all costs.
Python is from 1991. The only older language you listed was c.
Python is a millenial. He’s 34, is married and has two kids. But the old guys still think he’s 15.
COBOL handles the books because no one else can understand the system and it’s too much work to change after 40 years
Rust is that one rare type of guy who refuses to round measurements so you end up with “the drawer is 28.34646 inches tall.”
Clojure one is perfect lmao.
C is the old carpenter with leaky memory with heavy undiagnosed autism, who constantly cracks demented jokes like “Missing } at end of file”.
He’s so mentally not there in fact, that if you don’t specifically tell him to return to you after finishing the job, he will neither figure out what he’s supposed to do, nor will he tell you what went wrong, but instead he will happily jump somewhere else, halucinate commands from the structure of the walls and start doing whatever the voices tell him to do.
In my analogy, the tool is the programming language, and the worker is the programmer in that language. Mostly.
In your analogy, only C and C# mention using specific tools, unless you count mushrooms as tools ;)
I mean yeah lol. That’s why I said “mostly.” But my point was, more or less, that modern power tools can do stuff that you simply can’t do with C, but C is still a venerable tool to me. I like it. The old pros can make fantastic custom cabinets, they do framing almost as fast as someone with a nail gun, it’s just that it’s not practical for most people to try to get skilled enough to be able to make solid stuff (and of course you can never make a skyscraper with just hand tools.)
Once you start finding yourself using malloc() all that much, you’re probably using the wrong tool, and it’s also just objectively less secure than other safer languages. But clean C code has a kind of beauty to me that is hard to replicate in the more powerful languages.
Yeah and the new guy takes 3 days to finish the job that the old carpenter can do in 2hrs. And when he wants it done faster he quickly asks the old guy to do it for him. That’s why nobody else in the site likes him.
Python is my “native” programming language, it’s the first I learned, and many of my leaps in understanding of the language have resulted from thinking “Wait, Python is a smart ass. I bet it can do…”
I genuinely don’t get it.
That’s because it’s a stupid take. Believing brazil named a programming language after a Spanish word is pretty embarrassing too but I guess English speakers do that constantly.
'murica did send a president who made a toast to “the people of Bolivia”. During a dinner with the Brazilian president. In Brasilia. So, yeah, there’s precedent for their ignorance.
If that’s your bar…
also I just realized that Brazil did NOT make a programming language entirely in Spanish and call it “Si”
Imagine Python did this, and people would programming in Dutch!
If we’re continuing this analogy, did python or js take more drugs?
Don’t let Java try hallucinogens. It will get lost in the
public static void
.
What about philosophers who eat edibles?
C++?
now we are asking the real questions.
Who fucking cares use the tool you need.