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.

Second hand is now better than new

https://www.honest-broker.com/p/why-secondhand-is-now-better-than
1•rwmj•1m ago•0 comments

Should I uninstall every GUI app I use?

1•ankushkun_•1m ago•0 comments

Create a semi-working desktop only based on runtime Windows 3.10 shipped with W

https://tech.lgbt/@nina_kali_nina/115871854239918291
1•todsacerdoti•5m ago•0 comments

India's surveillance state and the future of democracy

https://www.washingtonpost.com/opinions/2026/01/09/india-surveillance-state-democracy/
1•thunderbong•5m ago•1 comments

One Man Rowing Alone in the South Atlantic Rescued

https://www.helsinkitimes.fi/finland/finland-news/domestic/28401-rescue-of-finnish-rower-jari-saa...
1•SebaSeba•5m ago•1 comments

Disposable software as extended cognition – discussion on R/PhilosophyOfMind

https://www.reddit.com/r/PhilosophyofMind/s/Kw6t4rM7kq
1•mcauldronism•6m ago•0 comments

I Worked at a Google Data Center: What I Saw Will Shock You [video]

https://www.youtube.com/watch?v=wLX_w0TtBpY
1•mgh2•6m ago•0 comments

Investigating Record-Based Domain Models

https://coding-mischief.com/?p=1
1•luca_takahashi•7m ago•1 comments

Solving the Founder Control vs. Capital Dilemma with Modular Equity Tokens

https://zenodo.org/records/18209805
1•iam_pri_s•11m ago•1 comments

The Linux audio stack demystified(2024)

https://blog.rtrace.io/posts/the-linux-audio-stack-demystified/
1•birdculture•13m ago•0 comments

How Grok's nudification tool went viral

https://www.theguardian.com/news/ng-interactive/2026/jan/11/how-grok-nudification-tool-went-viral...
1•n1b0m•15m ago•0 comments

Joy and Curiosity #69

https://registerspill.thorstenball.com/p/joy-and-curiosity-69
1•swah•17m ago•0 comments

AI Systems Engineering Patterns – Alex Ewerlöf Notes

https://blog.alexewerlof.com/p/ai-systems-engineering-patterns
1•kiyanwang•18m ago•0 comments

Moving Away from Agile: What's Next?

https://www.youtube.com/watch?v=SZStlIhyTCY
1•kiyanwang•19m ago•0 comments

Keeping 20k GPUs Healthy

https://modal.com/blog/gpu-health
2•birdculture•19m ago•0 comments

Outcomes > Learning Opportunities – By Shreyas Doshi

https://shreyasdoshi.substack.com/p/outcomes-learning-opportunities
1•kiyanwang•21m ago•0 comments

Show HN: pgwire-replication - pure rust client for Postgres CDC

https://github.com/vnvo/pgwire-replication
1•sacs0ni•22m ago•1 comments

Don't fall into the anti-AI hype

https://antirez.com/news/158
4•todsacerdoti•22m ago•0 comments

Timeline of the Human Condition|Milestones in Evolution and History

https://www.southampton.ac.uk/~cpd/history.html
1•hkhn•22m ago•0 comments

Why AI Agents Replaced the Arduino IDE in My ESP32 Projects [video]

https://www.youtube.com/watch?v=5DG0-_lseR4
1•zeristor•23m ago•0 comments

Show HN: ESPTimeCast – DIY WiFi Clock and Weather Station for ESP32 / ESP8266

https://github.com/mfactory-osaka/ESPTimeCast
1•m-factory•26m ago•0 comments

Is Orion's heat shield safe? New NASA chief's review on eve of flight

https://arstechnica.com/space/2026/01/nasa-chief-reviews-orion-heat-shield-expresses-full-confide...
2•smurda•27m ago•1 comments

Ad Blockers helped kill the open web

https://christianheilmann.com/2025/12/17/ad-blockers-helped-kill-the-open-web/
3•saeedesmaili•29m ago•0 comments

Show HN: Ambient Shield – Cinema mode for dual-monitor setups

https://ambient-shield.xyz
1•haka_•30m ago•0 comments

Live Coding Trance Music from Scratch in Strudel [video]

https://www.youtube.com/watch?v=iu5rnQkfO6M
1•sieste•31m ago•0 comments

Show HN: Bound – local code autocomplete LLM fine-tuned on your repository

https://bound.sh
1•misterchocolat•33m ago•0 comments

Exa.ai is indexing personal site data ignoring robots.txt

https://twitter.com/rbbydotdev/status/2010290966138396950
1•rbbydotdev•39m ago•0 comments

Show HN: Building a Recommender System for GitHub Repositories

https://gorse.io/posts/github-recsys.html
1•zhenghaoz•46m ago•0 comments

To Close or Not to Close

https://www.matsimon.dev/blog/to-close-or-not-to-close
1•close2•48m ago•0 comments

Ask HN: Is Web Development in a rut?

1•falloutx•53m ago•2 comments