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•1y ago

Comments

zoezoezoezoe•1y 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•1y 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.

Apple Sales Coach Will Use AI-Generated Video Presenters

https://www.macrumors.com/2026/05/12/apple-sales-coach-will-use-ai-generated-presenters/
1•ndr42•12s ago•0 comments

Show HN: UIGen – Production UI from any API spec with full override control

https://github.com/darula-hpp/uigen
1•ombedzi•1m ago•0 comments

Bambu Lab 3D printers: Never again

https://www.youtube.com/watch?v=eb48MdtNaDQ
1•chakintosh•2m ago•0 comments

You cannot sell AI written software

https://blog.habets.se/2026/05/You-cannot-sell-AI-written-software.html
1•abnercoimbre•3m ago•0 comments

Heartfelt

https://nicopr.fr/tmp/shades/heartfelt.html
1•bookofjoe•3m ago•0 comments

'I have an A because I use Chat'

https://www.msn.com/en-us/news/technology/i-have-an-a-because-i-use-chat-what-uc-students-say-abo...
1•danorama•3m ago•1 comments

" are ready to take your money"

https://www.rubenerd.au/are-ready-to-take-your-money/
1•speckx•5m ago•0 comments

Humanoid robots to become baggage handlers in Japan airport experiment

https://www.theguardian.com/world/2026/apr/28/humanoid-robots-baggage-handlers-japan-airports
1•PaulHoule•5m ago•0 comments

Incident with CodeQL

https://www.githubstatus.com/incidents/z3jhyg3l0dvx
1•chenrui•5m ago•0 comments

Treat Me Like an Investor

https://cameronwestland.com/treat-me-like-an-investor/
1•camwest•5m ago•0 comments

Fixing headline-only RSS feeds with RSS-fulltext

https://mijndertstuij.nl/posts/introducing-rss-fulltext/
1•mijndert•6m ago•0 comments

ChatGPT Performs Better on Julia Than Python for LLM Code Generation. Why?

https://www.stochasticlifestyle.com/chatgpt-performs-better-on-julia-than-python-and-r-for-large-...
1•thetwentyone•6m ago•0 comments

Ask HN: How do you keep up with blogs from people you follow?

1•kalinkochnev•6m ago•1 comments

Starting 1:1s on the Right Foot

https://personalis.io/blog/one-on-ones
1•sylvanjsmit•7m ago•0 comments

Thomas Massie Has Always Been a Pain in the Ass

https://www.motherjones.com/politics/2026/05/thomas-massie-has-always-been-a-pain-in-the-ass/
1•aworks•7m ago•1 comments

UK Biobank breach prompts the field of genomics to rethink open science

https://www.nature.com/articles/d41586-026-01520-w
1•Brajeshwar•8m ago•0 comments

Show HN: Grunden – Frontier AI inference hosted in Sweden, OpenAI-compatible

https://grunden.ai
1•fsrc•8m ago•0 comments

Lemmy Needs Diversity

https://somethingwonderful.eu/lemmy-needs-diversity.html
1•speckx•8m ago•0 comments

Interactive LLM ArXiv paper knowledge graph

https://gravity7.com/KnowledgeGraph/knowledge-graph.html
1•gravity7•8m ago•1 comments

Who Builds Your Judgment?

https://dekodiert.de/en/articles/wer-baut-eure-urteilskraft
1•sdoering•10m ago•0 comments

Could an El Niño this year match an 1877 event that killed millions?

https://www.washingtonpost.com/weather/2026/05/12/super-el-nino-1877-population-impacts/
2•howard941•10m ago•0 comments

Bare-metal STM32: vector table, linker script, and startup code from scratch

https://lmilz.dev/blog/2026/04/19/Embedded-Hello-World.html
1•lmilz•10m ago•0 comments

MockFIX – desktop FIX simulator so QA can test fills without a dev

https://www.mockfix.com/
1•roddytin•12m ago•0 comments

Ordnance Survey demands removal of all open data address datasets

https://www.owenboswarva.com/blog/post-addr86.htm
2•edent•12m ago•0 comments

Wallets and Credentials Are Here. Maturity Is Not

https://sphericalcowconsulting.com/2026/05/12/wallets-and-credentials-are-here-maturity-is-not/
2•mooreds•13m ago•0 comments

Python 3.15.0b1

https://www.python.org/downloads/release/python-3150b1/
2•gjvc•13m ago•0 comments

Bambu Lab is abusing the open source social contract

https://www.jeffgeerling.com/blog/2026/bambu-lab-abusing-open-source-social-contract/
3•rubenbe•13m ago•1 comments

The Iran War Is Taking the Color Out of Japan's Best-Known Snack Bags

https://www.nytimes.com/2026/05/12/world/asia/calbee-japan-bags-iran-war.html
4•reaperducer•14m ago•0 comments

Sustaining Rural Maternity Care in Colorado: From Crisis to Solutions

https://cpcqc.org/sustaining-rural-maternity-care-in-colorado-from-crisis-to-building-block-solut...
1•mooreds•14m ago•0 comments

CIAM in the Wild: Parking Lots

https://ciamweekly.substack.com/p/ciam-in-the-wild-parking-lots
1•mooreds•14m ago•0 comments