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

Comments

zoezoezoezoe•8mo 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•8mo 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: Maple – Multi-agent protocol with resource-aware scheduling

https://github.com/maheshvaikri-code/maple-oss
1•maheshvaikri99•1m ago•0 comments

Newsly – Analyze Polymarket Events

https://newsly.studio
1•polyGuest•5m ago•1 comments

Python 3.6-3.14 Performance on M1, M5 and Zen2

https://crewtech.se/b/1/index.html
1•apelapan•8m ago•1 comments

Elon Musk drops sustainable from Tesla's mission as he completes his villain arc

https://electrek.co/2025/12/26/elon-musk-drops-sustainable-teslas-mission-completes-villain-arc/
4•breve•9m ago•0 comments

Systems Are Sticky (2024)

https://dottedmag.net/blog/systems-are-sticky/
1•xk3•13m ago•0 comments

Ask HN: Anyone Still Using Snipcart?

1•youz•14m ago•0 comments

Machine-Driven Code Review

https://bits.logic.inc/p/code-review-without-bottlenecks
1•sgk284•15m ago•0 comments

The moral critic of the AI industry–a Q&A with Holly Elmore

https://www.foommagazine.org/the-moral-critic-of-the-ai-industry-a-q-a-with-holly-elmore/
1•paulpauper•16m ago•0 comments

Unknown Knowns: Five Ideas You Can't Unsee

https://linch.substack.com/p/unknown-knowns
1•paulpauper•16m ago•0 comments

Show HN: An app to learn about the world

1•davit_kocharyan•19m ago•0 comments

Nvidia-Groq deal is structured to keep 'fiction of competition alive'

https://www.cnbc.com/2025/12/26/nvidia-groq-deal-is-structured-to-keep-fiction-of-competition-ali...
3•1vuio0pswjnm7•21m ago•0 comments

Crafting Effective Conference Session Titles for 2026

https://julieyack.com/2025/12/26/ai-cant-save-a-bad-session-abstract-but-it-can-help-make-a-meh-o...
1•rbanffy•21m ago•0 comments

Trump Invited White South Africans to America. One Ended Up in Detention

https://www.nytimes.com/2025/12/26/us/trump-afrikaner-ice.html
3•vinni2•21m ago•0 comments

Israel becomes first country to formally recognise Somaliland as state

https://www.reuters.com/world/middle-east/israel-recognises-somaliland-somalias-breakway-region-i...
2•GaryBluto•26m ago•1 comments

Tmux and SSH Agent Forwarding

https://blog.feld.me/posts/2025/12/tmux-ssh-agent-forwarding/
1•zdw•26m ago•0 comments

A Wealth Tax Floated in California Has Billionaires Thinking of Leaving

https://www.nytimes.com/2025/12/26/technology/california-wealth-tax-page-thiel.html
6•vinni2•27m ago•2 comments

Show HN: Soil – Systematic autopsy database for dead organizations

https://www.soil.rip/
1•ostashenkods•28m ago•1 comments

Conservative and Christian? US right champions psychedelic drugs

https://www.theguardian.com/us-news/2025/dec/26/us-right-champions-psychedelic-drugs
1•bookofjoe•28m ago•0 comments

Show HN: Open source, self-hosted AI nutritionist for diabetes (Laravel/React)

https://github.com/acara-app/plate
1•tuvshaw•30m ago•1 comments

The William Wallace Effect

https://twitter.com/GruPiotr/status/2004673526679155065
1•piotrgrudzien•31m ago•0 comments

Extremal descendant integrals on spaces of curves: inequality proved with AI

https://arxiv.org/abs/2512.14575
1•thunderbong•31m ago•0 comments

E2EE Messaging Interoperability with MLS, Mimi and XMPP

https://2025.fossy.us/schedule/presentation/288/
1•transpute•32m ago•0 comments

Mouse: Computer Programming Language

http://mouse.davidgsimpson.com/
2•gappy•35m ago•1 comments

Ask HN: What's still broken in SoC 2 readiness and audit prep?

1•asdxrfx•37m ago•0 comments

Living Legends: Finance and Investing

https://olshansky.substack.com/p/living-legends-finance-and-investing
1•Olshansky•38m ago•0 comments

He made beer that's also a vaccine. Now controversy is brewing

https://www.sciencenews.org/article/vaccine-beer-polyomavirus-chris-buck
7•legionof7•38m ago•1 comments

Here is your next iPhone [video]

https://www.youtube.com/watch?v=Am0jSTDd58E
2•dgellow•39m ago•1 comments

How not to securely erase a Samsung NVMe drive (2024)

https://peterbabic.dev/blog/how-not-to-securely-erase-nvme-drive/?referrer=grok.com
1•transpute•40m ago•0 comments

Versioned Cache Keys Can Save You During Rolling Deployments

https://medium.com/dev-genius/version-your-cache-keys-to-survive-rolling-deployments-a62545326220
2•birdculture•40m ago•1 comments

Agent-O-rama: Scalable, Traceable, Stateful AI agents in Clojure or Java [video]

https://www.youtube.com/watch?v=mNLWtM3Iya4
1•1659447091•43m ago•0 comments