That looked like machine code on a 8-bit micro, perhaps the Commodore 64 or VIC-20 (based on the screenshot and 40x20 text). So that would be the 6502. Child’s play compared to what you’d need to do on a modern chip.
- 0 Posts
- 29 Comments
modeler@lemmy.worldto Programmer Humor@programming.dev•Which of these javascript expressions is false?1·2 months agoCan’t be C, C is the true path.
Completely agree.
People are tribal - they tend to conform to what the group thinks and does. We’re also primed with strong us vs. them tendencies, that is you want your team to win whatever happens.
As you say, if you believe that (for example) your friends and neighbours think democrats are radical socialists out to destroy American life, it would be highly dangerous to vote democrat let alone be on team democrat.
modeler@lemmy.worldto You Should Know@lemmy.world•YSK: Use ‘a’ when the word starts with a _consonant sound_, and ‘an’ when it starts with a _vowel sound_1·5 months agoThat was fantastic and a must-view for this topic.
modeler@lemmy.worldto You Should Know@lemmy.world•YSK: Use ‘a’ when the word starts with a _consonant sound_, and ‘an’ when it starts with a _vowel sound_1·5 months agoAnd don’t forget the napple!
modeler@lemmy.worldto No Stupid Questions@lemmy.world•Why Are People Surprised When Trump Actually Follows Through?3·5 months agoI think this is the primary reason, but I’ll add a couple of thoughts.
-
His people. The core of his actions right now is ‘project 2025’ which was written by an extreme right wing think tank in Washington called ‘The Heritage Foundation’. They’ve been around since Reagan and have been thought leaders in the GOP all this time. In other words, they know the system extremely well and they are well organised.
-
His supporters. A large number of his supporters are poor, Christian folk, often from red states. They are poor because the structure of the American economy has been designed to extract money from the non-rich and channel it to big business and rich individuals. Think Walmart and Musk. For 40 years GOP have been telling the lie that billionaires as job creators, that taxes, regulations and unions are bad, that trickle-down economics works. This has led to staggering amounts of money taken from the middle and working classes and piled into bank accounts of the real elites (here meaning billionaires and biggest companies). Trump’s supporters know the economy is rigged and they want to change it. Unfortunately they believe their church leaders (who have unabashedly instructed their flocks on politics and single issues like abortion) and the mainstream media (meaning Fox) who push these lies incessantly. The Democrats have not attacked (let alone resolved) these issues under Obama and Biden. But Trump claims he’ll shake up Washington as an outsider and tackle these issues. His supporters somehow do not equate a nepo baby, ivy-league educated billionaire ex-president as one of the elite. They think of him as ‘their man’.
In short, the propaganda from Fox, the Internet, their churches and their neighbours has persuaded them to vote against their interests and elect a group of elite political insiders and businessmen who have taken 4 years to plan the hostile takeover of the government in order to channel even more money to themselves.
-
modeler@lemmy.worldto World News@lemmy.ml•Two Russian colonels mysteriously ‘fall from upper-floor windows’3·5 months agoIt’s in the middle of a Russian winter so the central heating must have been belting out so much heat for the poor Colonel to open said window.
modeler@lemmy.worldto No Stupid Questions@lemmy.world•Why would a UTF-8 MySQL backup contain invalid UTF-8 characters?4·6 months agoThis is the right answer. I had the job of planning a schema update to fix this shitty design.
Saying that, unicode and character formats are incredibly complex things that are not easily implemented. For example two strings in utf-8 can contain the same number of characters but be hugely different in size (up to 3-4x different!). It’s well worth reading through some articles to get a feel of the important points.
modeler@lemmy.worldto No Stupid Questions@lemmy.world•Why is daisychaining multiple extension cords considered unsafe, even if only done to the length of a standard cable?143·7 months agoMany years ago, my mother used the electric lawn mower without unspooling all the wire. When it finally shorted, all the plastic wire insulation was in the process of turning into a melty plastic soup. A Lesson Was Learned.
The reason isn’t resistance - it’s that the coiled wire makes an electromagnet that stores energy in the magnetic field. The alternating current in the mains switches 50 or 60 times a second. In each cycle the magnetic field is created, destroyed then recreated in the opposite direction, then destroyed. This dumps a lot of energy (and therefore heat) into the coil.
modeler@lemmy.worldto science@lemmy.world•COVID-19 is a leading cause of death in children and young people in the US | University of OxfordEnglish3·7 months agoCar accidents, falls, drownings, poisonings (ie eating something you shouldn’t), fires. There are a lot of horrible ways to go.
All junior devs should read OCs comment and really think about this.
The issue is whether
is_number()
is performing a semantic language matter or checking whether the text input can be converted by the program to a number type.The former case - the semantic language test - is useful for chat based interactions, analysis of text (and ancient text - I love the cuneiform btw) and similar. In this mode, some applications don’t even have to be able to convert the text into eg binary (a ‘gazillion’ of something is quantifying it, but vaguely)
The latter case (validating input) is useful where the input is controlled and users are supposed to enter numbers using a limited part of a standard keyboard. Clay tablets and triangular sticks are strictly excluded from this interface.
Another example might be
is_address()
. Which of these are addresses? ‘10 Downing Street, London’, ‘193.168.1.1’, ‘Gettysberg’, ‘Sir/Madam’.To me this highlights that code is a lot less reusable between different projects/apps than it at first appears.
modeler@lemmy.worldto science@lemmy.world•Neutrinos: The inscrutable “ghost particles” driving scientists crazy5·1 year agoThe reference if you haven’t seen it.
Dara Ó Briain is a legend!
I don’t think that the anti-oop collective is attacking polymorphism or overloading - both are important in functional programming. And let’s add encapsulation and implementation hiding to this list.
The argument is that OOP makes the wrong abstractions. Inheritance (as OOP models it) is quite rare on business entities. The other major example cited is that an algorithm written in the OOP style ends up distributing its code across the different classes, and therefore
- It is difficult to understand: the developer has to open two, three or more different classes to view the whole algorithm
- It is inefficient: because the algorithm is distributed over many classes and instances, as the algorithm runs, there are a lot of unnecessary calls (eg one method on one instance has to iterate over many instances of its children, and each child has to iterate over its children) and data has to pass through these function calls.
Instead of this, the functional programmer says, you should write the algorithm as a function (or several functions) in one place, so it’s the function that walks the object structure. The navigation is done using tools like
apply
ormap
rather than a loop in a method on the parent instance.A key insight in this approach is that the way an algorithm walks the data structure is the responsibility of the algorithm rather than a responsibility that is shared across many classes and subclasses.
In general, I think this is a valid point - when you are writing algorithms over the whole dataset. OOP does have some counterpoints encapsulating behaviour on just that object for example validating the object’s private members, or data processing for that object and its immediate children or peers.
As I was discussing this with my partner we summarised this as:
Humans have always had the capacity for violence and murder; as populations grew, acts of violence could be larger, both in terms of number of combatants and also length of time of continuous fighting. This is a progression of:
- Small bands of people skirmishing with neighbours to
- Towns sending small raiding bands to
- Cities fielding an army for a summer campaign to
- Empires furnishing professional armies and sending them on multi-year campaigns, to
- Nation states using advanced logistics to maintain millions of soldiers in the field for years at a time.
Somewhere between city-states and full modern nation states, there have been full on campaigns of genocide. But genocide can be thought here definitionally as only possible with some significant number of people.
Unfortunately there is a deep dark part of the human psyche that has always been with us.
I hear what you’re saying, but there’s a counterpoint to this.
In prehistoric times, population densities were low. In mesolithic times (hunter gatherers) there were simply no concentration of people large enough to wipe out or to do the killing. Nothing could be called genocide at this time.
In neolithic times (the first farmers) violence was definitely a part of life. Some early towns do show signs that they were destroyed. But again, population densities are low enough that the scale of violence would not be enough to call ‘genocide’. It’s a town burnt down with everyone murdered, not a ‘people’ - whatever that might mean at this time. This is not about egalitarianism - it’s population density.
However as we move to the bronze age, there are definitely signs that large scale events occur that might fit into the modern concept of genocide but archeological evidence is severely lacking. The main line I would argue is that the male lines of the neolithic farmers in Europe are hammered and almost completely replaced with the Yamnaya Y chromosomes across a huge expanse - from the east european plains to the Iberian peninsula. Genetic continuity with the neolithic farmers is maintained though indicating that male newcomers were having children with local women, and very few male locals had children. During this event the culture changed hugely - burial patterns, material goods, etc.
I don’t know if we can call this genocide - at least the full modern concept - because these changes took centuries to roll out across the expanse of Europe, but they speak to local conquests and, at the very least, the newcomers prevented local males from having their own families. At worst you can imagine a constant expansion of this new culture taking control of new areas, killing the men, taking local women as concubines and eradicating their gods, customs and ways of living. Quite a lot of genocidal checklist items ticked off there.
By the mid to later bronze age, genicide is definitely a widespread thing, recorded in many texts.
The paradox of tolerance.
If people are tolerant of intolerance, tolerance dies. So, ironically, people who are otherwise highly tolerant people (especially when they have thought about this deeply) realise they must reject intolerance loudly and intensely, lest their way of life is destroyed.
modeler@lemmy.worldto Programmer Humor@programming.dev•As someone not in tech, I have no idea how to refer to my tech friends' jobs2·1 year agoSurely that is reserved for QA!
modeler@lemmy.worldto Python@programming.dev•CPython PR merged yesterday: Allow disabling the GIL with `PYTHON_GIL=0` or `-X gil=0` by swtaarrs · Pull Request #116338 (part of PEP 703)7·1 year agoNote the caveat:
With PYTHON_GIL=0 set, I spot-checked a few tests and small programs that don’t use threads. They all seem to run fine, and very basic threaded programs work, sometimes. Trying to run the full test suite crashes pretty quickly, in test_asyncio
modeler@lemmy.worldto Web Development@programming.dev•Tailwind vs. normal CSS - performance and size17·1 year agoTheir arguments included the size of the web page, and the time to display the first content, both of which were significantly better in Nue when compared to Tailwind.
By all means argue on what is important (because what is important for your projects may be significantly different from mine), but there were many points that the author was highlighting, not just the separation of concerns. And for my projects, all these concerns are important.
BASIC
DATA
statement? Wow you were so lucky. On my ZX81 we had to enter them as characters in aREM
statement that was the first line of code so we knew their address so that we could execute it. Address Space Layout Randomization? Couldn’t work on the ZX81!