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

Comments

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

Show HN: Zush – Native macOS menu bar app that AI-renames your images

https://www.zushapp.com/
1•lirik•1m ago•1 comments

You don't need to pay for third-party AV software to protect your PC anymore

https://www.howtogeek.com/you-dont-need-to-pay-for-third-party-antivirus-software-to-protect-your...
1•Corrado•2m ago•0 comments

Scorigami (football)

https://en.wikipedia.org/wiki/Scorigami
1•quuxplusone•4m ago•0 comments

Selfish AI

https://www.garfieldtech.com/blog/selfish-ai
1•todsacerdoti•8m ago•0 comments

DeepSeek-R1 Is Mathematically Bound to Hallucinate

https://gist.github.com/eric2675-coder/1ad468ce9daf8235b6936b812feb531b
1•eric2675•9m ago•0 comments

Show HN: A $200 DuckDB UI VSCode extension

https://github.com/ChuckJonas/duckdb-vscode
1•cjonas•11m ago•0 comments

At a clown school near Paris, failure is the lesson

https://www.npr.org/2026/02/01/nx-s1-5683115/france-gaulier-clown-school
1•1659447091•13m ago•0 comments

Iterabledata: Python lib to read and process and iterable data files

https://github.com/datenoio/iterabledata
1•ibegtin•15m ago•1 comments

Compiling Rust to readable C with Eurydice

https://lwn.net/SubscriberLink/1055211/6f51ebe751ce69a9/
1•todsacerdoti•16m ago•0 comments

Git-Link, an Emacs package to create links to Git objects

https://github.com/sshaw/git-link
1•mbork_pl•17m ago•1 comments

Top AI Image Enhancers in 2026: Free vs. Paid Real-World Tests

https://notegpt.io/ai-essay-writer
1•Ali-780•18m ago•1 comments

Advanced Square Foot Calculator

https://play.google.com/store/apps/details?id=com.sqftcalc.app&hl=en_US
2•Gigacore•23m ago•0 comments

Claudia Sahm on Kevin Warsh

https://stayathomemacro.substack.com/p/kevin-warsh
3•m-hodges•24m ago•1 comments

Show HN: Paramancer – Claude Code for Iterative 3D Models

https://www.paramancer.app
1•cdr6934•24m ago•2 comments

Brain cooling collar trial for head injury patients

https://www.bbc.com/news/articles/cq5yxwejen4o
2•1659447091•24m ago•0 comments

Huge fossil bonanza preserves 512-million-year-old ecosystem

https://www.newscientist.com/article/2513485-huge-fossil-bonanza-preserves-512-million-year-old-e...
1•teleforce•24m ago•0 comments

OpenClaw

https://github.com/openclaw/openclaw
1•simonebrunozzi•25m ago•0 comments

Mahatma Gandhi, the Missing Laureate

https://www.nobelprize.org/prizes/themes/mahatma-gandhi-the-missing-laureate/
1•thunderbong•25m ago•0 comments

Show HN: Joy_a mood tracker that feels like Inside Out meets Duolingo

https://letsfancy.com/joy
1•letsfancy•35m ago•0 comments

Welcome to the Room

https://www.jsnover.com/blog/2026/02/01/welcome-to-the-room/
1•Ozzie_osman•35m ago•0 comments

Are we dismissing AI spend before the 6x lands? (2025)

https://martinalderson.com/posts/are-we-dismissing-ai-spend-before-the-6x-lands/
3•ukuina•35m ago•0 comments

"Solving" Wordle from Shared Scores at 100%* Accuracy

https://marcoshuerta.com/posts/wordle_bluesky/
1•plaguna•40m ago•0 comments

How do you track contact lens replacement?

1•swetahs1•47m ago•1 comments

What Cloud Platforms Fear Most?

1•pennypeinee88•1h ago•0 comments

Vibe: Easy VM sandboxes for LLM agents on macOS

https://github.com/lynaghk/vibe
3•todsacerdoti•1h ago•0 comments

Chat Was the UI. Agents Are the Architecture

https://billykaplan.io/blog/agents-are-the-architecture/
1•billy1kaplan•1h ago•1 comments

Leaked Chats Expose the Daily Life of a Scam Compound's Enslaved Workforce

https://www.wired.com/story/the-red-bull-leaks/
8•smurda•1h ago•0 comments

Six things we're learning from 1.5M AI agents self-organizing in a week

1•abrandes•1h ago•1 comments

Show HN: Claude Launcher – TUI to fuzzy search and resume Claude Code sessions

https://github.com/imprakharshukla/claude-launcher
1•imprakharshukla•1h ago•0 comments

Genie3 Video Loop Generator – create seamless game-style loops in ~30s

https://genie3-video.org/
1•linkshu•1h ago•1 comments