frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Throwaway Code: Don't recycle, throw it away (2017)

https://www.sung.codes/blog/2017/throwaway-code-dont-recycle-throw-away
26•sails•11mo ago

Comments

RedShift1•11mo ago
It'll be a cold day in hell before I start throwing away my 80+ "New" notepad++ tabs.
notTooFarGone•11mo ago
i feel called out.

I had to manage my 350 notepad++ new tabs as I migrated to a new PC - it was not pretty.

mehulashah•11mo ago
There’s something beautiful about not being riddled with previous artifacts and starting clean with how you imagine you want to build your system. If the system is large enough, you can’t do it that often.
gherkinnn•11mo ago
It is a mistake to believe that the code written is the only valuable artefact.

What you've learned along the way is so much more important.

eternityforest•11mo ago
I usually find most of the learning happens a year later when I see if my approach is maintainable and handles new requirements.

When I'm actually coding, I'm usually not learning as much, because I'm generally intentionally choosing boring tech everyone already knows.

Most of the learning is less about deeply internalizing concepts and more about things like new features in the Python stdlib.

gitroom•11mo ago
Ive got a million messy files saved up, honestly, even when I know just letting go could help me think clearer. Ever wonder if holding onto old stuff slows you down or actually helps you get smarter over time?
1dom•11mo ago
I don't think the author is necessarily advocating the throwing away of code here, they're advocating the value of being able to rapidly prototype and move on from seemingly incomplete things.

The whole value proposition of the digital world is that we can store and manipulate it for virtually nothing: there isn't the same cost to having digital stuff, and so there isn't the same gains from throwing it away IMO.

athrowaway3z•11mo ago
Create a ~/Archive and throw it in there.

A quick grep every blue moon can be faster than wrangling a LLM into place, and as an added bonus you can look back and laugh at how big of an idiot you were.

klabb3•11mo ago
In my experience, if you have a medium sized task with multiple unknowns, it is best to prototype aggressively without a thought about quality, and then start a second iteration with quality in mind. The purpose of the prototyping is learning.

It’s faster (yes) than prototype-then-fixup. Why? Because the ”live refactor” is harder than the greenfield writing phase. The new knowledge often makes the impl straightforward.

It’s also better quality than design-then-build. The optimal architecture and modularization change with knowledge increase, which is best to get via experience. You can design fully upfront but it’s riddled with analysis paralysis - it’s notoriously hard (and slow) to predict unknowns.

Sounds like good advice? Well, the hardest part isn’t to follow it – it’s to know upfront what size of task it is. If it turns out to be easier, you waste a bit of work (prototype-fixup is faster). However, if it’s bigger than you thought – you’re in the best possible position to break down the new problem into subtasks, with no wasted work.

perrygeo•11mo ago
If you could package this up in a motivational poster, it belongs in every company meeting room. Speed and quality are not two opposing forces to tradeoff. We can have both.

But we need to get rid of this silly, infantile, unwavering attachment to our source code files. Throw code away. All. the. time. The first version of code is, by definition, being built in the absence of critical information. Why on earth would we get so attached to that which was built in ignorance? In this case we're not "reusing code", we're throwing away knowledge!

Why would you discard everything valuable you learned in favor of a code artifact written before you learned it? Throw away the code instead! Surely the code written AFTER gaining the knoweldge will be both faster and better quality. (and more clear, less tech debt, etc)

dsabanin•11mo ago
Very well said. This is such an important point.

I believe that if you truly accept what Hemingway said, that writing is rewriting, you get less attached to the idea of reaching the best design on the first try, and feel better when starting with a suboptimal solution.

Of course this sometimes conflicts with organizational pressures, where that quick and dirty solution may be deemed as enough by some and you won't get to finish with the proper design. For me the trick is to consider first version just an internal stage of work on a feature, not even communicated outwards most of the times, until the appropriate design is reached.

cadamsdotcom•11mo ago
We need better words for the different code written for different purposes.

Code written to learn and explore a problem space? Sure.

Code written in response to a prompt, which could easily be rewritten - things like a throwaway “please tell me a story about the contents of this CSV for me and also write code to graph it”. Yep throw it away.

Or keep it as an example for a later model.

That’s very different to code written to high standards intended for others’ use.

We need different words for all of those 3 varieties of code.

Cybersecurity looks like proof of work now

https://www.dbreunig.com/2026/04/14/cybersecurity-is-proof-of-work-now.html
289•dbreunig•1d ago•106 comments

The paper computer

https://jsomers.net/blog/the-paper-computer
14•jsomers•2d ago•0 comments

Stealth Satellite TV Defeats Iran's Internet Blackout

https://spectrum.ieee.org/iran-internet-blackout-satellite-tv
10•WaitWaitWha•1h ago•0 comments

A Better Ludum Dare; Or, How to Ruin a Legacy

https://ldjam.com/events/ludum-dare/59/$425291/$425292
20•raincole•2h ago•0 comments

I made a terminal pager

https://theleo.zone/posts/pager/
77•speckx•5h ago•18 comments

Google broke its promise to me – now ICE has my data

https://www.eff.org/deeplinks/2026/04/google-broke-its-promise-me-now-ice-has-my-data
1202•Brajeshwar•9h ago•533 comments

God sleeps in the minerals

https://wchambliss.wordpress.com/2026/03/03/god-sleeps-in-the-minerals/
478•speckx•14h ago•99 comments

Cal.com is going closed source

https://cal.com/blog/cal-com-goes-closed-source-why
234•Benjamin_Dobell•12h ago•173 comments

Introduction to Spherical Harmonics for Graphics Programmers

https://gpfault.net/posts/sph.html
29•luu•2d ago•2 comments

PiCore - Raspberry Pi Port of Tiny Core Linux

http://tinycorelinux.net/5.x/armv6/releases/README
87•gregsadetsky•7h ago•10 comments

Retrofitting JIT Compilers into C Interpreters

https://tratt.net/laurie/blog/2026/retrofitting_jit_compilers_into_c_interpreters.html
51•ltratt•15h ago•10 comments

Live Nation illegally monopolized ticketing market, jury finds

https://www.bloomberg.com/news/articles/2026-04-15/live-nation-illegally-monopolized-ticketing-ma...
443•Alex_Bond•8h ago•129 comments

YouTube now lets you turn off Shorts

https://www.theverge.com/streaming/912898/youtube-shorts-feed-limit-zero-minutes
225•pentagrama•3h ago•96 comments

Anna's Archive loses $322M Spotify piracy case without a fight

https://torrentfreak.com/annas-archive-loses-322-million-spotify-piracy-case-without-a-fight/
354•askl•19h ago•383 comments

A Mercury Rover Could Explore the Planet by Sticking to the Terminator

https://www.universetoday.com/articles/a-mercury-rover-could-explore-the-planet-by-sticking-to-th...
13•bookofjoe•5d ago•3 comments

Show HN: Hiraeth – AWS Emulator

https://github.com/SethPyle376/hiraeth
5•ozarkerD•1h ago•1 comments

PBS Nova: Terror in Space (1998)

https://www.pbs.org/wgbh/nova/mir/
29•opengrass•4d ago•9 comments

The Gemini app is now on Mac

https://blog.google/innovation-and-ai/products/gemini-app/gemini-app-now-on-mac-os/
103•thm•10h ago•51 comments

Arguing with Agents

https://blowmage.com/2026/04/14/arguing-with-agents/
47•asaaki•1h ago•25 comments

Hacker News CLI (2014)

https://pythonhosted.org/hackernews-cli/commands.html
39•rolph•5h ago•15 comments

CRISPR takes important step toward silencing Down syndrome’s extra chromosome

https://medicalxpress.com/news/2026-04-crispr-bold-silencing-syndrome-extra.html
93•amichail•11h ago•57 comments

Fixing a monitor that goes black, off or blinks due to static electricity (2023)

https://aalonso.dev/blog/2023/how-to-fix-monitor-that-goes-black-off-due-to-static-electricity-in...
121•cyclopeanutopia•3d ago•67 comments

Ask HN: Who is using OpenClaw?

236•misterchocolat•8h ago•285 comments

How can I keep from singing?

https://blog.danieljanus.pl/singing/
57•nathell•1d ago•17 comments

Agent - Native Mac OS X coding ide/harness

https://github.com/macOS26/Agent
9•jv22222•3h ago•0 comments

Do you even need a database?

https://www.dbpro.app/blog/do-you-even-need-a-database
217•upmostly•15h ago•253 comments

Adaptional (YC S25) is hiring AI engineers

https://www.ycombinator.com/companies/adaptional/jobs/k7W6ge9-founding-engineer
1•acesohc•10h ago

Ohio prison inmates 'built computers and hid them in ceiling (2017)

https://www.bbc.com/news/technology-39576394
84•harambae•5h ago•74 comments

The Universal Constraint Engine: Neuromorphic Computing Without Neural Networks

https://zenodo.org/records/19600206
11•skinney_uce•3h ago•5 comments

Forcing an inversion of control on the SaaS stack

https://www.100x.bot/a/client-side-injection-inversion-of-control-saas
80•shardullavekar•5d ago•44 comments