Skip Navigation

InitialsDiceBearhttps://github.com/dicebear/dicebearhttps://creativecommons.org/publicdomain/zero/1.0/„Initials” (https://github.com/dicebear/dicebear) by „DiceBear”, licensed under „CC0 1.0” (https://creativecommons.org/publicdomain/zero/1.0/)BA
Posts
32
Comments
4,490
Joined
2 yr. ago

  • Aluminium is actually a better conductor than copper when you judge it by mass, not volume. I think also by tensile strength.

    In any case there's a reason that large overland wires aren't copper, but steel-cladded aluminium. Copper will always have its applications but so does gold and yet we're not running out of gold to plate connections with.

    In cases like windings requiring more volume is actually an issue, in the case of PCBs... no, despite Apple's insistence, it's actually fine to have a phone that's 0.2mm thicker.

  • How does executing a program actually work?

    Way too long an answer for a lemmy post

    It has an executable flag, but what actually happens in the OS when it encounters a file with an executable file?

    Depends on OS. Linux will look at the first bytes of the file, either see (ASCII) #! (called a shebang) or ELF magic, then call the appropriate interpreter with the executable as an argument. When executing e.g. python, it's going to call /usr/bin/env with parameters python and the file name because the shebang was #!/usr/bin/env python.

    How does it know to execute “main”?

    Compiled C programs are ELF so it will go through the ELF header, figure out which ld.so to use, then start that so that it will find all the libraries, resolve all dynamic symbols, then do some bookkeeping, and jump to _start. That is, it doesn't: main is a C thing.

    Is it possible to have a library that can be called and also executed like a program?

    Absolutely. ld.so is an example of that.. Actually, wait, I'm not so sure any more, I'm getting things mixed up with libdl.so. In any case ld.so is an executable with a file extension that makes it look like a library.

    EDIT: It does work. My (GNU) libc spits out version info when executed as an executable.

    If you want to start looking at the innards like that I would suggest starting here: Hello world in assembly. Note the absence of a main function, the symbol the kernel actually invokes is _start, the setup necessary to call a C main is done by libc.so. Don't try to understand GNU's libc it's full of hystarical raisins I would suggest musl.

  • It's fine memes are permitted to make jokes and it's more of a paradigm than vibe coding.

    The one paradigm that's actually missing is logic programming, I would've gotten rid of unstructured to include it. The whole paradigm thing really only started with Dijkstra's rant about unstructured gotos (not the ones C has, in C you can't jump to the middle of another function).

  • Of course Germany won't extradite we don't extradite nationals to non-EU countries. It can even happen that we don't extradite Americans to the US because they can demonstrate that they're likely to face torture in the US, such as isolation cells.

  • Autistic coders are only slightly more rare that autistic rail fans. There's no shortage of you guys in the field.

    what you are doing should have a clear connection with some goal, or be clearly a goal in itself, otherwise you’ll achieve nothing.

    "Understanding the whole stack" would, necessarily, be the second kind of goal. And you'll never get there as the field is evolving under your feet.

  • Yes, then you have another problem - how do you choose what you want to do if you don’t yet understand the whole in any approximation.

    How did you decide to write English using the Latin alphabet? You did not, I presume, study the whole ancestry of the alphabet back to Hieroglyphs to understand it in it's entirety (did you know that 'A' is an upside-down ox head?), nor did you study alternative spellings, nor did you study linguistics to make sure that English, Modern English in particular, truly, is the best choice of language.

    You were able to ignore all that, why are you not able to ignore things elsewhere?

    And selective ignorance, btw, is a key skill to aquire as a coder. Encapsulation, abstraction, action at a distance being the root of all evil, all those are key principles to understand and skills to acquire. Why? Because you're not as smart as you wish you were. Being good at ignoring things, being good at saying "if I build it like this, I can from now on ignore the details" is the only way to do anything of any complexity. I don't care how my pants are constructed, about the lubrication the loom uses, I care whether they fit, are comfortable, durable.

    When figuring out what to pack for vacation, do you already tetris your shirts and pants? Nah, that comes later. Right now, worry about not forgetting your sunglasses, don't worry, they'll fit somehow.

    There’s a barrier a person has to grind through with their teeth before they understand that they want to learn Haskell and what that is.

    Nah. Just start somewhere. If you later on realise that your interests lie elsewhere, then switch, but don't fret: If it was interesting enough to look at, how could it have been a waste of time.

  • How the hell do you cross the gap between these and actual understanding? Other than the blind way of going up level after level, starting with a bipolar transistor, which doesn’t seem easy at all.

    You don't pretend that Haskell has anything to do with electrical engineering and then you're golden. You do not need to understand the one to understand the other. You do not need to understand quantum mechanics to understand a transistor, either -- I mean, sure, if you intend to develop process nodes then you better understand quantum mechanics, but if you plan on soldering transistors together until you get an FM receiver? Who cares. Learn to read datasheets, that's the actual skill you'll need.

    You choose some random interest and learn it and don't look higher up or deeper down the stack, you respect the abstraction boundaries, until and unless you actually have a good reason to cross them.

  • The Rust book is also good at teaching coding, but it would be more of a jump into cold water. It's still more about teaching coders about Rust, only teaching coding incidentally to pick up people coming from a variety of languages, instead of getting into the core of computation itself.

  • Have you already heard of our Lord and Saviour, the Wizard, and the scripture known as The Wizard Book? By the end of it you will be able to write a compiler, be a smith who can forge their own tongs.

    (The software to use with the book is nowadays called racket, use #lang sicp to enable the right dialect)

  • Cause when it stops being glamorous magic, it starts becoming optimized and normal, like painting fences.

    The portrait kind of painter working like the fence kind is not a good thing. It's not even a thing at all, it's an illusion.

    Also when it comes to accessibility for the aspiring hobbyist coding is very accessible. If you have nothing to start with, sure, more expensive than knitting, but probably not more expensive than acquiring a merino wool habit, and if you already have any kind of computer, any, as well as an internet connection, it's literally free. The tools, the knowledge, everything. Willingness to learn not included.

  • The question is rather "how many people have a metro station within walking/biking distance" and "how many long-haul trips do you need to make".

    Over here we don't set aside half a day (or more) to to drive to walmart to buy groceries for a fortnight, we pick stuff up as we need it when we're out, anyway. Dropping into the supermarket to grab some things is like a five minute detour if you know what you need and where it is. You can spend the metro ride thinking about what to cook, buy what you need, then get going.

    According to statistics commute times in Europe are actually slightly longer than in the US, but that doesn't take into account that combining trips is much easier over here and that riding public transport gives you time to, whatnot, knit, biking or walking counts as exercise, while driving a car counts as, at best, nothing, at worst, the road rage will ruin your day.

    I'm not saying that you, personally, can flip a switch and make it work for you, on the contrary: The reason that you're not doing it organically is because the infrastructure where you live is right-out designed to not make it work for you. What I suggest is that instead of saying stuff like "It cannot be the case that Europeans are living better lives, they must be imagining things" you say, to your compatriots, "How are those bloody europoors better at this we are supposed to be the best let's figure out how to beat them". Or at least that's how I imagine motivating Americans looks like.

  • but that’s just not feasible for real working class Americans in the economic system as it is currently

    Nothing to do with economics, everything to do with city planning and resource allocation. Public transit and bikes are a bad option in the US because the transit is completely underfunded, "only poor people take the bus", and bike paths, even pedestrian paths (if they even exist) are sent on detours around car infrastructure instead of cutting through everything.

    And then you have to juggle picking up your child from childcare, etc with is ridiculous without a car.

    My mum did just fine first coming by with the bike, putting me on the back seat, then swinging by the supermarket, groceries in the front basket, later on coming by with the bike, me riding along on my own, still swinging by the supermarket. We were driving on calm backstreets and through a park which was actually the most direct route, much more direct than with a car as you'd have to get onto the collector, first. Got more than one kid to wrangle? Put them in a trailer, or get a suitable cargo bike. They can even have seatbelts.

    No, you don't need a warehouse full of washing machines in every neighbourhood. People don't shop for washing machines daily. People don't need cars to shop for them, either, delivering bulky stuff makes a ton of sense. Groceries? Wherever you were that day, a supermarket should only be like a two or three minutes detour.

    And it's not like European cities didn't go down the car-centric route, mind you. Difference being we realised it's a stupid idea.

  • Nothing wrong with being a peasant, in this context: History is full of peasant revolts. People in the European middle ages were perfectly aware of how the system was stacked against them. Arguably, more than they're now.

  • centralised democracy

    I think you mean democratic centralism.

    "Centralised democracy" I think would make sense when contrasting parliamentarian vs. direct democracy. None of the ML parties ever implemented democratic centralism but bureaucratic centralism (ie. party leaders decide, base follows). It was never intended to be an organisation principle for a whole country, just a party, OTOH it's a neat way to dress up autocracy as democracy so of course it's been done plenty of times.

    Lenin described the SPD as democratically centralist and well, yes, maybe back then. The structures are still in place but the whole party is paralysed when it comes to making decisions so in the end the Seeheimer rule, i.e. the neoliberal wing. It's a rather perverse situation: An actually still lefty base, or at least union people, following a neoliberal vanguard with red paintjob.