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

Comments

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

Cognitive science can help us design better software – CogZest

https://cogzest.com/2026/04/how-cognitive-science-can-help-us-design-better-software/
1•LucCogZest•59s ago•0 comments

137-Year-Old Piece of Eiffel Tower to Be Auctioned in Paris

https://www.nytimes.com/2026/04/09/world/europe/eiffel-tower-auction.html
1•paulpauper•1m ago•0 comments

A Chatting Website That Uses Nostr

https://inbondz-chat.pages.dev
1•wasimsk•1m ago•0 comments

The Effects of Gender Integration on Men: Evidence from the U.S. Military

https://academic.oup.com/qje/advance-article/doi/10.1093/qje/qjag016/8551347?login=false
1•paulpauper•1m ago•0 comments

Show HN: Bloomberg Terminal for LLM ops – free and open source

1•amans9712•1m ago•0 comments

What explains heterogeneity in AI adoption?

https://www.siliconcontinent.com/p/what-explains-heterogeneity-in-ai
1•paulpauper•1m ago•0 comments

Draining Wallets via Prompt Injection in Coinbase AgentKit

https://457e884c.x402warden-blog.pages.dev/research/coinbase-agentkit-prompt-injection/
1•xxmrlnxx•3m ago•0 comments

The Process Is the Product

https://tylermaran.substack.com/p/the-process-is-the-product
1•themanmaran•3m ago•0 comments

The Rational Conclusion of Doomerism Is Violence

https://www.campbellramble.ai/p/the-rational-conclusion
2•thedudeabides5•4m ago•0 comments

Average Is All You Need

https://rawquery.dev/blog/average-is-all-you-need
1•AlexC04•4m ago•0 comments

Multiplicity

https://m-u-l-t-i-p-l-i-c-i-t-y.org/
1•marukodo•5m ago•0 comments

Consensus Formation and Change Are Enhanced by Neutrality

https://advanced.onlinelibrary.wiley.com/doi/10.1002/advs.202512301
1•PaulHoule•5m ago•0 comments

Warp DB

https://warp.thegeeksquad.io/
1•thunderbong•6m ago•0 comments

Gram 1.0 Released

https://gram.liten.app/posts/first-release/
1•DiabloD3•6m ago•0 comments

I Built an Autonomous Flying Umbrella [video]

https://www.youtube.com/watch?v=EYRrUiM_A6g
1•CharlesW•7m ago•0 comments

Show HN: Mcptube – Karpathy's LLM Wiki idea applied to YouTube videos

https://github.com/0xchamin/mcptube
1•0xchamin•7m ago•0 comments

Hermes Agent (by Nous Hermes) quickly ranked #1 on OpenRouter

https://twitter.com/Teknium/status/2043122514986139763
1•larodi•7m ago•1 comments

After Criticizing Pope, Trump Posts Image of Himself as a Jesus-Like Figure

https://www.nytimes.com/2026/04/13/us/politics/trump-jesus-pope-leo-truth-social-post.html
1•treetalker•8m ago•1 comments

Texas Tech cancels academic programs "centered on" sexual orientation, gender

https://www.texastribune.org/2026/04/10/texas-tech-ban-gender-identity-sexual-orientation-academics/
1•hn_acker•9m ago•1 comments

Configuration flags are where software goes to rot

https://00f.net/2026/04/11/config-flags/
1•mperham•9m ago•0 comments

You're gonna need a bigger benchmark, METR

https://www.lesswrong.com/posts/3SywPAjGQWCtQFafb/you-re-gonna-need-a-bigger-boat-benchmark-metr
1•frmsaul•10m ago•0 comments

Problems Before the Real Problem: The First Lessons of Apollo 13

https://w3.ibm.com/ibm/open-innovation-community/initiatives/69ba803f20eb5edfdccbbb90
2•flyingbarron•11m ago•0 comments

From Pal to Verilog: Writing the A4092 Logic from Scratch

https://amiga.technology/blog/from-pal-to-verilog/
1•freediver•11m ago•0 comments

Cozy Cafe Idle Game

https://beans.cozyidle.click/
1•kstaykov•12m ago•0 comments

Patterns.dev Skills

https://github.com/PatternsDev/skills
3•iqen93•12m ago•0 comments

Flowers for Algernon

https://en.wikipedia.org/wiki/Flowers_for_Algernon
1•tosh•14m ago•0 comments

For Ants, a 'Cleaning Station' in the Desert

https://www.nytimes.com/2026/04/13/science/harvester-cone-ants-cleaning.html
1•marojejian•14m ago•1 comments

HiFloat4 Format for Language Model Pre-Training on Ascend NPUs

https://arxiv.org/abs/2604.08826
1•rbanffy•15m ago•0 comments

The 0.25% Background: Building a Rarity System into a Portfolio Site

https://eric.mann.blog/building-a-rarity-system-into-a-portfolio-site/
1•eamann•15m ago•0 comments

Show HN: Aeolus – a library for unified access to air quality sensor networks

https://github.com/southlondonscientific/aeolus
1•ruaraidh•15m ago•0 comments