frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Avoid Continue

https://www.teamten.com/lawrence/programming/avoid-continue.html
2•todsacerdoti•9mo ago

Comments

zoezoezoezoe•9mo ago
I dont know if I fully agree. Sure, there is definitely an argument the be had about whether or not `continue` is the best word to use in this instance, but why avoid it entirely? Every programmer is able to easily understand what code like this would do:

``` for (Node node : nodeList) { if (node.isBad()) { continue; } processNode(node); } ```

Every keyword in any programming language is largely arbitrary in my opinion let's take a look at the beginning of the codeblock `for (Node node : nodeList)` also completely arbitrary, though it's clear to anyone who's ever written C++ that it is equivalent to saying "for every node in nodeList".

Continue is not meant to read as "continue execution" it's meant to be "continue to the next item of the list", and I think avoiding it entirely is a pointless effort.

Ukv•9mo ago
I feel `skip` may have been a better name, but disagree with it being logically difficult to parse beyond that.

If I'm reading a loop and see

    for x in y {
        if exclusions.contains(x) { skip; }
        if x.children.length == 0 { skip; }
        if os.file.exists(x.name) { skip; }
        ...
I instantly know that processing for those elements is skipped, and they won't be relevant for the rest of the loop.

Whereas if I see

    for x in y {
        if !exclusions.contains(x) {
            if x.children.length != 0 {
                if !os.file.exists(x.name) {
        ...
I feel like there's still mental overload with not knowing where those `if` blocks end, and so having to keep the conditions in mind. It doesn't immediately tell me that the rest of the loop is being skipped.

The `log()` mistake seems no less likely to happen using early-returns in function instead, and I'd argue nesting checks actually introduces more room for that kind of error overall, where you append something at the end within the wrong set of brackets, compared to a flatter structure.

When two years of academic work vanished with a single click

https://www.nature.com/articles/d41586-025-04064-7
1•wawayanda•3m ago•0 comments

Munros, Corbetts, Grahams and Donalds: What's the Difference?

https://www.thehighlandmountaincompany.co.uk/post/munros-corbetts-grahams-and-donalds-what-s-the-...
1•RicoElectrico•3m ago•0 comments

A high-performance, minimalist visual board for spatial thinkers

https://vb.lokryn.com
1•jen_lokryn•5m ago•1 comments

A Codebase by an Agent for an Agent

https://ampcode.com/by-an-agent-for-an-agent
1•pbshgthm•8m ago•0 comments

Show HN: Ghostree is a Ghostty fork with worktree management built in

https://github.com/sidequery/ghostree
1•nicoritschel•9m ago•0 comments

Python 3.14 Remote Debugging and Claude Code = Pwnage

https://github.com/promptromp/python-remote-debug-skill
2•adamhadani•9m ago•1 comments

Show HN: Computer Chronicles

https://computerchronicles.tv
1•LeoPanthera•12m ago•0 comments

LED lighting undermines visual performance unless supplemented by wider spectra

https://www.nature.com/articles/s41598-026-35389-6
6•bookofjoe•12m ago•0 comments

What the world can learn from Paris's cycling revolution

https://momentummag.com/what-the-world-can-learn-from-pariss-cycling-revolution/
1•fanf2•14m ago•0 comments

Spreadsheets and Vi and JSON

https://awalgarg.me/untitled_project
2•todsacerdoti•14m ago•0 comments

Sagas (2012)

https://vasters.com/archive/Sagas.html
1•locknitpicker•14m ago•0 comments

Cori – Give agents safe DB write access without raw SQL (open source in Rust)

https://github.com/cori-do/cori-kernel
2•bringitup•15m ago•1 comments

UK to reimburse visa fees for AI and quantum researchers

https://www.timeshighereducation.com/news/uk-reimburse-visa-fees-ai-and-quantum-researchers
1•rbanffy•16m ago•0 comments

House of Lords votes for under-16s social media ban

https://www.computing.co.uk/news/2026/legislation-regulation/peers-vote-for-under-16-social-media...
2•rbanffy•17m ago•2 comments

Hand-Crafting Domain-Specific Compression with an LLM

https://engineering.nanit.com/hand-crafting-domain-specific-compression-with-an-llm-3c42f5c2b070
1•miedwar•20m ago•0 comments

RAG for Legacy Systems: 7,432 Pages to 3s Answers

https://clouatre.ca/posts/rag-legacy-systems/
3•french_exec•25m ago•0 comments

WorldChaosMap: A live map of global instability

https://www.worldchaosmap.app/
2•shawsuraj•25m ago•1 comments

VPN Comparison Spreadsheet

https://old.reddit.com/r/rateVPNs/comments/1gw58mk/the_ultimate_vpn_comparison_spreadsheet/
1•scapecast•27m ago•0 comments

Show HN: A lightweight, native macOS menubar app for monitoring with mini graphs

https://github.com/bluewave-labs/systempulse
1•gorkemcetin•28m ago•0 comments

Software Design Principles That Matter

https://newsletter.francofernando.com/p/software-design-principles-that-matter
2•rmason•29m ago•1 comments

The '3.5% rule': How a small minority can change the world

https://www.bbc.com/future/article/20190513-it-only-takes-35-of-people-to-change-the-world
3•choult•29m ago•0 comments

Watch This Futuristic Windshield Melt Ice Almost Instantly

https://www.thedrive.com/news/watch-this-futuristic-windshield-melt-ice-almost-instantly
1•PaulHoule•29m ago•0 comments

Gemba

https://en.wikipedia.org/wiki/Gemba
1•wjb3•31m ago•0 comments

PickYourVC: Find the right VC for your next round

https://pickyourvc.com/
1•panrobo•31m ago•1 comments

Semantic Attacks: Exploiting What Agents See

https://niyikiza.substack.com/p/semantic-attacks-exploiting-what
1•niyikiza•32m ago•1 comments

Guinness Adverts Project on Irish Film Institute's Archive Player

https://www.irishcentral.com/culture/guinness-adverts-project-irish-film-institute
1•gnabgib•32m ago•0 comments

We've given up on keeping our initial arch docs/specs up to date.Should I worry?

1•yutea_dem24•32m ago•0 comments

Stackmaxxing for a recursion world record [video]

https://www.youtube.com/watch?v=WQKSyPYF0-Y
1•btdmaster•32m ago•0 comments

Turn Your Android into a Dumb-Phone

https://rasmuskirk.com/articles/2026-01-16_turn-your-android-into-a-dumbphone/
2•bitterblotter•32m ago•0 comments

Show HN: Promo/offer code sharing and discovery for apps

https://proffer.codes/
1•indest•34m ago•0 comments