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

Comments

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

Anthropic's Mythos model accessed by unauthorized users

https://www.reuters.com/technology/anthropics-mythos-model-accessed-by-unauthorized-users-bloombe...
1•c420•1m ago•0 comments

AI Server Demand to Drive Memory Contract Price Increases in 2Q26

https://www.trendforce.com/presscenter/news/20260331-12995.html
1•Sibexico•4m ago•0 comments

MCP Scope Creep Is a Runtime Problem, Not a Prompt Problem

https://sunglasses.dev/blog/mcp-scope-creep-runtime-problem
1•azrollin•5m ago•1 comments

Gbench Intelligence Benchmark

https://gertlabs.com/
3•gertlabs•6m ago•0 comments

ENIAC's Architects Wove Stories Through Computing

https://spectrum.ieee.org/eniac-80th-anniversary-weaving
1•sohkamyung•7m ago•0 comments

Maze of Doom (self-changing) simulation [video]

https://www.youtube.com/watch?v=-1ryPxPVsf8
1•graphai•8m ago•1 comments

TPM software for Intel Macs / Windows systems

https://flextpm.com/
1•thewhitekanye•12m ago•1 comments

Ravix – An AI agent that runs on your Claude Code subscription (alpha)

2•raunaksingwi•17m ago•0 comments

A text adventure, all in Markdown

https://vas-blog.pages.dev/markdown-adventure
1•s314•18m ago•0 comments

Misconceptions About Majority Rule

https://groupincome.org/2016/09/misconceptions-about-majority-rule/#user-content-fnref-5
1•gslepak•22m ago•0 comments

Webby Person of the Year: Claude

https://winners.webbyawards.com/2026/specialachievement/476/claude
1•watusername•22m ago•0 comments

Unauthorized group has gained access to Anthropic's exclusive cyber tool Mythos

https://techcrunch.com/2026/04/21/unauthorized-group-has-gained-access-to-anthropics-exclusive-cy...
1•jnord•26m ago•1 comments

Submit your startup profile with Claude or ChatGPT. 60 seconds or less

https://www.startuphub.ai/agents/submit
1•compulsivebuild•27m ago•0 comments

Higher education's frozen yogurt moment

https://www.washingtonpost.com/opinions/2026/04/19/yale-report-shows-colleges-universities-face-r...
1•paulpauper•28m ago•0 comments

AI was ruining my college philosophy classes. So I assigned a new kind of essay

https://globeopinion.substack.com/p/ai-was-ruining-my-college-philosophy
1•paulpauper•28m ago•0 comments

A forty-year-old problem, briefly available

https://www.parahealth.ai/company/dispatch/thesis
1•dylburns•31m ago•0 comments

Ray-Ban Meta and Oakley Meta AI Glasses Officially Available in Singapore

https://cnalifestyle.channelnewsasia.com/style-beauty/ray-ban-meta-and-oakley-meta-ai-glasses-sin...
1•kelt•32m ago•0 comments

Learning Material for Idiomatic Rust

https://corrode.dev/blog/idiomatic-rust-resources/
1•lwhsiao•32m ago•0 comments

Show HN: gcx – The Official Grafana Cloud CLI

https://github.com/grafana/gcx
1•annanay•33m ago•0 comments

Lufthansa cuts 20k flights to save money, fuel

https://www.upi.com/Top_News/World-News/2026/04/21/lufthansa-flight-cuts/6391776813766/
3•petethomas•36m ago•1 comments

Cursor partners with SpaceX on model training

https://cursor.com/blog/spacex-model-training
2•gzer0•39m ago•1 comments

NASA's Webb Helped Rule Out Asteroid's Chance of 2032 Lunar Impact

https://science.nasa.gov/blogs/webb/2026/03/06/how-nasas-webb-helped-rule-out-asteroids-chance-of...
1•mooreds•44m ago•0 comments

Drunk Post: Things I've Learned as a Senior Engineer

https://luminousmen.substack.com/p/drunk-post-things-ive-learned-as
4•zdw•47m ago•1 comments

Bloom filters: the niche trick behind a 16× faster API – Blog – incident.io

https://incident.io/blog/bloom-filters
5•birdculture•48m ago•0 comments

Enriching MMDB files with your own data using Go (2020)

https://blog.maxmind.com/enriching-mmdb-files-with-your-own-data-using-go/
1•mooreds•53m ago•0 comments

Developing Theory about the Development of Theory [pdf]

https://mintzberg.org/sites/default/files/article/download/developing_theory_about_the_developmen...
3•rzk•57m ago•0 comments

How Much Do GPU Clusters Cost?

https://newsletter.semianalysis.com/p/how-much-do-gpu-clusters-really-cost
2•stosssik•59m ago•0 comments

New Lazarus Apt Campaign: "Mach-O Man" macOS Malware Kit Hits Businesses

https://any.run/cybersecurity-blog/lazarus-macos-malware-mach-o-man/
1•lnguyen•1h ago•0 comments

Fuck you, pay me" by mike monteiro

https://www.youtube.com/watch?v=jVkLVRt6c1U
1•fuzztester•1h ago•1 comments

AI bot buying what agents can buy in 2026

https://dialtoneapp.com/2026/april/ai-bot-buying-report
2•fcpguru•1h ago•0 comments