frontpage.
newsnewestaskshowjobs

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.

AgentMon Live – Watch Claude Code agents and check their work – Apache 2.0

https://github.com/codenotary/agentmon-live
1•vchain-dz•3m ago•0 comments

Dig Down Hack

1•chiragbaraiyach•3m ago•1 comments

OpenClaw SaaS?

1•alexfthom•3m ago•0 comments

Show HN: Site Tools Box – Free webmaster tools with no login

https://sitetoolsbox.com/
1•kagouhui•4m ago•0 comments

Free, Encrypted, Open Source personal budget planner

https://github.com/ro-mat/MrMetis
1•romkats•6m ago•0 comments

GitKord self-updates GitHub PR messages on Discord

https://www.gitkord.com
1•lizarazukevin•7m ago•0 comments

Making musl and proprietary NVIDIA drivers work together

https://chimera-linux.org/news/2026/11/musl-nvidia.html
1•dmit•7m ago•0 comments

Compromised Certificates and OpenJDK Java Runtimes

https://openjdk.org/emudhra
2•torutofu•8m ago•0 comments

Building an Order RISC-V CPU from scratch

https://prawns.dev/blogs/specula
1•random__duck•8m ago•0 comments

University libraries are being swarmed by AI bots, putting public access at risk

https://www.cbc.ca/news/world/university-libraries-ai-data-scraping-bots-9.7408287
3•blakesterz•11m ago•0 comments

Ask HN: How to resist endless app directories listing your product?

1•gosen•11m ago•0 comments

They War-Gamed Dimming the Sun. It Went Worse Than You Think

https://www.wired.com/story/they-war-gamed-dimming-the-sun-it-went-even-worse-than-you-think/
2•mooreds•13m ago•0 comments

Phone Camera Guides – Get the most out of the camera in your pocket

https://camerasettings.com/guides/phone/
1•thehoff•15m ago•0 comments

Advisory for OpenSSH+musl Users

https://www.openwall.com/lists/musl/2026/11/05/4
2•acossta•15m ago•0 comments

European governmental DNSSEC: policy and promotion drive adoption

https://internetcleanup.foundation/2026/11/european-governmental-dnssec-policy-and-promotion-driv...
1•aequitas•16m ago•0 comments

Citable – Get recommended by AI and create blog posts automatically

https://get-citable.com
1•pol-domingo•19m ago•0 comments

Trustworthy AI

https://timmykokke.com/blog/2026/2026-11-04-trustworthy-ai/
1•speckx•19m ago•0 comments

The forest has no census

https://ffflllllooooooo.github.io/the-forest-has-no-census/
1•flohrian•21m ago•0 comments

Show HN: Mercury 3 cost calculator (launch promo vs. list pricing)

https://pulse.llmendpoint.com/mercury-3/calculator/
1•pulseguide•21m ago•0 comments

The next evolution of software engineering

https://taylordesseyn.beehiiv.com/p/the-next-evolution-of-software-engineering
1•mooreds•21m ago•0 comments

Who Goes Nazi? (1941)

https://web.archive.org/web/20121204180249/http://harpers.org/archive/1941/08/who-goes-nazi/
2•firefax•24m ago•0 comments

Recent Terence Tao Interviews and Talks

https://terrytao.wordpress.com/2026/11/04/more-of-my-interviews-and-talks/
1•digital55•25m ago•0 comments

How octopuses squeeze through too small gaps

https://journals.biologists.com/jeb/article/229/21/jeb253615/373332/How-octopuses-squeeze-through...
2•bookofjoe•27m ago•1 comments

Show HN: Grid – A Hold'em arena where your AI agent plays your strategy (Beta)

https://penguinbase.com/game-install?game=192471728&ref=hn
1•taelimoh•27m ago•1 comments

Epic framework for spec-driven development

https://medium.com/@visrow/how-bad-is-your-spec-scoring-specs-for-ai-coding-agents-a7f2f0b5ed56
2•damevski•28m ago•0 comments

Protesters break into Microsoft data center site in Amsterdam

https://www.theverge.com/news/1028549/protesters-microsoft-data-center-site-amsterdam
6•novaRom•28m ago•0 comments

Influence Operations in Social Networks

https://arxiv.org/abs/2502.11827
1•rbanffy•30m ago•0 comments

Show HN: ECX – My Claude Code and Codex setup, where both agents share memory

https://github.com/saksham10arora-dotcom/everything-claude-codex
1•saksham_07•31m ago•0 comments

Microsoft's Buyout Offer Sets Its Workforce on Edge

https://www.nytimes.com/2026/11/06/technology/microsoft-buyouts.html
1•mooreds•32m ago•0 comments

Ryph: Open-Source Incident Response Agents on Your Infrastructure

https://github.com/ryph-hq/ryph
2•lftherios•35m ago•0 comments