Are there any examples of 'perfect' software?
from fortnitefinn@sh.itjust.works to programming@programming.dev on 15 Feb 15:28
https://sh.itjust.works/post/55375651
from fortnitefinn@sh.itjust.works to programming@programming.dev on 15 Feb 15:28
https://sh.itjust.works/post/55375651
I’m talking about programs that can’t be improved no matter what. They do exactly what they’re supposed to and will never be changed.
It’ll probably have to be something small, like cd or pwd, but does such a program exist?
#programming
threaded - newest
TempleOS
The dev of left-pad made it perfect by removing it.
No; since every user defines the perfect program differently. Which should be the default behaviour(s)?
You cannot criticize a good knife by asking why it’s not a hammer.
But I can critisize it for having only one sharp edge instead of 2. Or for being too short or too long. Or for having a handle that’s not shaped well for my hand. (That last metaphor is probably the correct one for the sentiment I’m going for.)
The answer remains, this tool is not flawed, it’s just not the one you want.
Vim could be feature-complete and formally verified and I’m still using Xed.
A hammer is a completely different tool, but different defaults in a single program are not.
Point is there’s no objective standard for “perfect”
Software is always an ongoing conversation.
I would have said Windows notepad but they screwed the pooch on that one and changed it.
notepad++
They recently experienced an self-update hijack. Plenty of room for improvement.
That was a server side compromise, but the update function could have detected it with more security features so you’re still right.
Ski Free
Notepad.exe, pre-windows 11. Now it’s something else entirely but still uses the name :(
Notepad did what it needed to do, but it could be improved in a lot of ways
Nah it was eternally annoying that it didn’t support Unix line endings. Also there are clearly a ton of basic features that people want from lightweight text editors.
Notepad in Windows 7 occasionally did some weird shit.
I kinda love snipping tool.
LaTeX
Error: Too many unprocessed floats.
Not sure about LaTeX, but TeX is widely considered to be almost “perfect” code.
TeX will be perfect after Knuth dies and the version number is incremented to π.
ugh, no way. It might do a fine job with typesetting, but the user experience is utterly awful and that’s very unlikely to change because of design choices over 40+ years. If you don’t think so, give typst a real try.
Semantic round brackets make typst impossible to use for me. If it had curlies instead it would be great.
Yeah you probably can’t do to much more to
pwdoryesor whatever (yeah I know about the silly optimisations). I think once you get much beyond that there are always more features you can add. Even for something likecd, people have made fancier versions with fuzzy matching and so on.The flight software for the Apollo moonshots.
Honestly, it all starts going to shite after “hello world.”
Hahahahah
Shouldn’t it be “Hello world.”?
What does perfect hello world even mean? It can be realized in many ways and none is the best way.
Computers can’t even greet you in the real world. Its like some kind of sick joke.
“Dance, clanker! Dance!”
No. “Hello, world!” or you’re doing it wrong.
Automotive engine control computers.
They just work, for decades and millions of miles.
Pretty subjective but if you’re looking for do one thing and do it well I’d go with some of the GNU core utils like you mentioned, vlc & ffmpeg for AV media, and sl for being a silly way to handle ls typos
You may be interested by this en.wikipedia.org/wiki/Formal_verification.
Of course: github.com/kelseyhightower/nocode
Ha. I still have an open PR on that.
Perfect code right here:
yes
Is there a perfect building?
Probably not, since they exist in an environment — which is constantly changing — and are used by people — whose needs are constantly changing.
The same is true of software. Yes, programs consist of math which has objective qualities. But in order to execute in the physical world, they have to make certain assumptions which can always be invalidated.
Consider fast inverse sqrt: maybe perfect, for the time, for specific uses, on specific hardware? Probably not perfect for today.
Nope.
I’ve thought about this before, and it gave me an interesting thought process: AI can’t ever be good at doing a large project.
It has a hard limit. Not only is it not as good as us, the best it can ever do is as good as us, and we’re not even good at it. That’s all it can be trained on! Our garbage code lol
Pkzip version 2.04g
WinRAR free version
Pretty certain cd and pwd have changed over the years. The kernel hasn’t remained the same so the commands that use it wont and now we have faster methods to do various things like getting file data the commands that depend on it will change. Less quickly than something that is still gaining features but bit rot is a very real effect since every single part of software is in constant flux.
I don’t think such thing as perfect software exist, only abandoned software. If the environment changes, then the software needs changes too.
Or a new software.
Or a rewrite in Rust.
There was a moment in time where maybe it was qmail:
https://en.wikipedia.org/wiki/Qmail
More on how it was accomplished:
https://blog.acolyer.org/2018/01/17/some-thoughts-on-security-after-ten-years-of-qmail-1-0/
Many might disagree, but imo vim is the perfect text editor for a command line interface. It’s just so simpel and does exactly what I need it to do without doing anything unnecessary
neovim is a drop in replacement for vim that fixes the issues that bother me with vim
Might install that then in the future, if I remember it. Sudo apt-get install vim is just so ingrained in muscle memory
Vim has some pretty messy design… Starting at some of the action quirks and ending at vim9script
Never heard of vim9script, what is it. I must admit I don’t use it for a lot of super complicated tasks just regular yaml and file editing. At for that it’s perfect imo
Nit: vim is a visual editor. It has a text interface, but it’s not a command line interface.
An example of a command line text editor would be sed.
I know it isn’t a cli but a text editor that you can use in a terminal, if there’s any other difference i got wrong feel free to correct me
7zip?
Depends on your definition of “perfect” and “improved”. Is it perfect because it does one fundamental thing really well? Is it improved by adding new features?
I think what you’re meaning is, is there a program that is ubiquitous (or at least works anywhere), will basically remain used forever because it does a fundamental job that will always need to be done, and it does that job in the most straightforward way possible that can’t be made any algorithmically simpler, faster, etc. Probably plenty, honestly. Bitwise operations, arithmetic, fetch/store, etc. Though ubiquity/working anywhere gets rarer the higher you go from hardware. Even your suggestion of cd, for example, has to interface with an OS’s file system, of which there are several common types. What it’s doing is simple in concept, but will always be dependent on other programs for the file system.
Some Quines maybe?
TeX. Best documented source, and last bug found was 12 years ago.