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•10mo ago

Comments

zoezoezoezoe•10mo 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•10mo 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.

Show HN: TerraViz – Real-time flights, earthquakes, ISS on one map

https://www.terraviz.live/
1•cvaambikapur•38s ago•0 comments

Show HN: I no longer monitor my coding agents, my desktop pet does

https://github.com/SwarmPack/SwarmWatch
1•prastik•2m ago•0 comments

DIY YouTuber powers an EV using 500 disposable vapes

https://www.notebookcheck.net/DIY-YouTuber-powers-an-EV-using-500-disposable-vapes.1239016.0.html
1•WM6v•12m ago•0 comments

Show HN: LEAX – CLI tool for analyzing C memory leaks with AI-assisted fixes

https://github.com/hooop/leax
1•emmmarti•12m ago•0 comments

Chimpanzees Are into Crystals

https://www.nytimes.com/2026/03/04/science/chimpanzees-crystals.html
1•jimnotgym•14m ago•0 comments

Max Sxhwarzer: I've decided to leave OpenAI

https://xcancel.com/max_a_schwarzer/status/2028939154944585989
1•doener•16m ago•0 comments

Can you defend your AI decisions?

https://codingsoul.org/2026/03/02/can-you-defend-your-ais-decisions/
1•hleichsenring•20m ago•1 comments

All top AI models in one place – GPT, Claude, Gemini, Grok

https://www.chatgoat.ai/en
1•HollisQi•24m ago•0 comments

Welcome to the Wasteland: A Thousand Gas Towns

https://steve-yegge.medium.com/welcome-to-the-wasteland-a-thousand-gas-towns-a5eb9bc8dc1f
3•weltview•25m ago•0 comments

Apple Studio Display XDR Supports Dicom Medical Imaging for Diagnostic Radiology

https://www.macrumors.com/2026/03/03/studio-display-xdr-dicom-medical-imaging/
1•tosh•26m ago•0 comments

When Reasoning Becomes a Trap: Gemini 3 Flash in FoodTruck Bench

https://foodtruckbench.com/blog/gemini-flash
1•Munksgaard•27m ago•0 comments

Au Revoir, Eleventy

https://hamatti.org/posts/au-revoir-eleventy/
2•Tomte•34m ago•0 comments

RFC 9849. TLS Encrypted Client Hello

https://www.rfc-editor.org/rfc/rfc9849.html
4•P_qRs•36m ago•0 comments

Altman's "sloppy" mistake works in Anthropic's favor [video]

https://www.youtube.com/shorts/ZklG_j10-IA
1•mdp2021•36m ago•1 comments

How Important Was the Battle of Hastings?

https://www.historytoday.com/archive/head-head/how-important-was-battle-hastings
3•benbreen•37m ago•1 comments

Fluid Cryptography Challenge

https://nests.zeabur.app/
1•realpaer•37m ago•1 comments

China uses AI doctor clones to help patients and improve healthcare

https://zoneofasia.com/china-uses-ai-doctor-clones-to-help-patients-and-improve-healthcare/
2•teleforce•40m ago•0 comments

Unmasking Redacted Names in Epstein Files Using Computer Vision (Open Source)

https://www.youtube.com/watch?v=mKK9VPito-E
2•birdculture•45m ago•1 comments

GPUI Mobile: Zed's GPUI Framework to iOS (Metal) and Android (Vulkan) in Rust

https://github.com/itsbalamurali/gpui-mobile
3•itsbalamurali•48m ago•1 comments

Tell HN: I got Claude Max for my open source project

4•asim•50m ago•2 comments

I built a local-first stock valuation tool based on Damodaran's methodology

https://github.com/stockvaluation-io/stockvaluation_io
3•softcane•51m ago•2 comments

Show HN: PulseWatch – AI-powered website change monitoring with visual selectors

https://pulsewatch.watch
2•KaracaTR•51m ago•0 comments

UN calls for investigation into deadly strike on school in Iran

https://www.reuters.com/world/middle-east/un-urges-investigation-into-horrific-attack-iran-school...
4•nerdyadventurer•55m ago•0 comments

The Influence of Anxiety: Harold Bloom and Literary Inheritance

https://thepointmag.com/examined-life/the-influence-of-anxiety/
3•apollinaire•59m ago•0 comments

Show HN: Mcpfs – Mount MCP servers as FUSE filesystems

https://github.com/airshelf/mcpfs
2•evoleinik•1h ago•0 comments

What Is Code Review For?

https://blog.glyph.im/2026/03/what-is-code-review-for.html
1•ingve•1h ago•0 comments

Israel Is Blowing Up Iran's Police State to Clear the Way for a Revolt

https://www.wsj.com/world/middle-east/israel-is-blowing-up-irans-police-state-to-clear-the-way-fo...
2•breppp•1h ago•0 comments

Show HN: Cloudwright – validate, cost, and export cloud architectures from text

https://github.com/xmpuspus/cloudwright
2•xmpuspus•1h ago•0 comments

Show HN: SPOTLYTT - STANDOUT AND GET DISCOVERED BY SKILLS

https://spotlytt.com
1•pbs29•1h ago•2 comments

Quiet War: The Polity, The Terminator, and AI takeover

https://yadin.com/notes/quiet/
1•dryadin•1h ago•0 comments