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.

RemotePower – self-hosted fleet monitoring with built-in vulnerability scanning

https://github.com/tyxak/remotepower
1•tyxak•4m ago•0 comments

Show HN: I was drowning in browser tabs, so I built this

https://microsoftedge.microsoft.com/addons/detail/gopeek/ffaeanmhghmohbponokefmbhfkkomnmk
2•formit34•4m ago•1 comments

Icon.museum – A curated gallery of app icon design

https://icon.museum
1•akashwadhwani35•4m ago•0 comments

Impossible Challenge

https://itch.io/jam/impossible-challenge
1•alisio85•5m ago•0 comments

Terminal-Bench Challenges: long-horizon, token-intensive, single-task benchmarks

https://www.tbench.ai/news/terminal-bench-challenges
1•matt_d•5m ago•0 comments

High-performance code intelligence MCP server

https://github.com/DeusData/codebase-memory-mcp
1•giamma•5m ago•0 comments

Show HN: Redteam:If you are using more than 2 coding agents

https://github.com/AscendyProject/redteam
1•rkdgh19•10m ago•0 comments

Usbliter8 an A12/A13 SecureROM Exploit

https://ps.tc/pages/blog-usbliter8.html
1•Cider9986•12m ago•0 comments

Ukrainian drone makers target Asia as Taiwan tensions spur demand

https://www.reuters.com/world/china/ukrainian-drone-makers-target-asia-taiwan-tensions-spur-deman...
1•JumpCrisscross•12m ago•0 comments

HN with pics – a visual hcker.news reader

https://hn.is-ai-good-yet.com/
1•ilyaizen•17m ago•0 comments

Dana Scott: Lambda Calculus, Forcing and the Foundations of Math: #14 aboutlogic [video]

https://www.youtube.com/watch?v=opLbbZ-_AWE
1•matt_d•19m ago•0 comments

Prodigy: AI Employees

https://docs.google.com/presentation/d/1aldEHGR_1Hv_F0UlTuQIL8mXhsw5s5VzuuPcgKV5czY/edit?usp=sharing
2•samayashar•23m ago•2 comments

We built a status page service on Cloudflare

https://ampliflare.com/blog/status-page-cloudflare-architecture/
1•powerpurple•25m ago•1 comments

I tested Gemma4 12B on my 8GB GPU, now I don't want to go back to smaller models

https://www.xda-developers.com/tested-google-gemma-4-12b-on-8gb-gpu-and-dont-want-to-go-back-to-s...
1•theanonymousone•26m ago•0 comments

Make-work and Sub-subsistence work

https://wilsoniumite.com/2026/06/19/make-work-and-sub-subsistence-work/
1•Wilsoniumite•27m ago•0 comments

'We created a monster': companies rein in AI usage as costs strain budgets

https://www.ft.com/content/1d37cc08-e0aa-45a4-a45d-4ad282529314
2•JumpCrisscross•27m ago•0 comments

One Model Won't Save You: How We Built Our AI Stack

https://www.xelerate.tech/one-model-wont-save-you/
1•pedrocha•29m ago•0 comments

Mantyx – Batteries Included Managed Agent Runtime

https://mantyx.io/
1•mantyx•29m ago•0 comments

Show HN: Write SaaS apps where users control where their data is stored

https://github.com/wolfoo2931/linkedrecords/
1•WolfOliver•35m ago•0 comments

Disney+ Is Down

https://mashable.com/tech/disney-plus-down-outage
2•01-_-•36m ago•0 comments

I Replaced My Custom Next.js Portfolio with a Markdown First Site Engine

https://muhammadhaseeb.me/blog/why-koji
1•iamhaseeb•36m ago•0 comments

Contributor Poker and Zig's AI Ban

https://kristoff.it/blog/contributor-poker-and-ai/
2•birdculture•41m ago•0 comments

It looks like Elon Musk has a Giganormous tax bill coming

https://bsky.app/profile/bgrahamdisciple.bsky.social/post/3mokv2qdksc2m
2•doener•45m ago•2 comments

Google Is Using Nvidia's Playbook to Build a Rival AI Chip Business

https://www.wsj.com/tech/ai/google-is-using-nvidias-playbook-to-build-a-rival-ai-chip-business-1e...
2•doener•50m ago•0 comments

The Invisible Force of Brand Awareness

https://sofiamb.substack.com/p/the-invisible-force-of-brand-awareness
1•MelloS•51m ago•0 comments

Tirith – Detect terminal injection, homograph, and pipe-to-shell attacks

https://tirith.sh/
1•d3Xt3r•54m ago•0 comments

Building Reliable Agentic AI Systems

https://martinfowler.com/articles/reliable-llm-bayer.html
1•Garbage•59m ago•0 comments

Ordered Key Sharding in DynamoDB

https://death.andgravity.com/albumtitle
2•genericlemon24•1h ago•0 comments

Bernie Sanders unveils $7T plan to give Americans control of AI industry

https://arstechnica.com/tech-policy/2026/06/bernie-sanders-unveils-7-trillion-plan-to-give-americ...
3•asymmetric•1h ago•2 comments

Microsoft discovers new lightweight backdoor that steals cryptocurrency

https://arstechnica.com/security/2026/06/microsoft-spots-new-self-propagating-malware-for-stealin...
1•joozio•1h ago•0 comments