If you didn't care about efficiency, why not use bubblesort?
Because the animation needs to pretend to use something more efficient.
I coded something dumb and I'm proud of it
31–40 of 88 posts
Re: I coded something dumb and I'm proud of it
#32this is an evil take but i think emojis are massively, massively underrated for use in signaling information (and massively overused in git readmes) A grimacing emoji when a process is thrashing, a fire emoji when it's eating CPU, a sweating smile emoji when the process is running longer than expected, etc etc etc. It sounds dystopian in a way but also useful - neat seeing them used here!
Re: I coded something dumb and I'm proud of it
#33Another way to describe what has been done: implement a pure function and avoid storing additional state. It sounds way less dumb that way. It is not really a pure function but the spirit is here. I've done the same during a refactoring of a side-project recently. It handles the input/output to a MIDI controller with many buttons, knobs and matching LEDs. Instead of computing what LED should change at regular interva…
Where it goes awry and gets complicated is that web developers want to modify the input state directly within the same functions that produce the output state, and they also want to trigger side effects after the output state has been completed, requiring another pass.
I’ve built a React variant for video compositing. Since it renders at a steady frame rate, there’s no reason to ever trigger re-renders. The useState() and useEffect() hooks are practically useless. To my personal taste it’s a sweet spot for React, and I wonder if some kinds of web apps might benefit from similar simplification to the state approach.
Re: I coded something dumb and I'm proud of it
#34Earlier quoted context omitted.
"What are letters?" "Kinda like mediaglyphs except they're all black, and they're tiny, they don't move, they're old and boring and really hard to read." -- The Diamond Age (Neal Stephenson)
How would they have learned a contraction if everything is based on glyphs/ images?
Re: I coded something dumb and I'm proud of it
#35Earlier quoted context omitted.
"What are letters?" "Kinda like mediaglyphs except they're all black, and they're tiny, they don't move, they're old and boring and really hard to read." -- The Diamond Age (Neal Stephenson)
How would they have learned a contraction if everything is based on glyphs/ images?
"Goodbye" = "God be with ye" for example
You don't think "will not" when you say "won't", "won't" is just a word you use with a meaning you understand long before you can write.
Re: I coded something dumb and I'm proud of it
#36Earlier quoted context omitted.
"What are letters?" "Kinda like mediaglyphs except they're all black, and they're tiny, they don't move, they're old and boring and really hard to read." -- The Diamond Age (Neal Stephenson)
How would they have learned a contraction if everything is based on glyphs/ images?
Re: I coded something dumb and I'm proud of it
#37this is an evil take but i think emojis are massively, massively underrated for use in signaling information (and massively overused in git readmes) A grimacing emoji when a process is thrashing, a fire emoji when it's eating CPU, a sweating smile emoji when the process is running longer than expected, etc etc etc. It sounds dystopian in a way but also useful - neat seeing them used here!
Personally, I disagree. I'm probably in the minority, but emojis don't helot me much when conveying information and I see them more as visual clutter that makes it difficult to distinguish what's going on. This is especially the case when there are a lot of emojis (or other icons for that matter) instead of text, e.g. in menus. It makes it much harder for me to distill the information and it takes me longer to grok w…
Re: I coded something dumb and I'm proud of it
#38this is an evil take but i think emojis are massively, massively underrated for use in signaling information (and massively overused in git readmes) A grimacing emoji when a process is thrashing, a fire emoji when it's eating CPU, a sweating smile emoji when the process is running longer than expected, etc etc etc. It sounds dystopian in a way but also useful - neat seeing them used here!
Emojis are incredible for variable names in code, it solves the hard problem of naming things.