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

Comments

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

Pentagon Adopts Incel-Speak

https://www.theguardian.com/science/2026/mar/01/incel-slang-mainstream-government-media
1•zabzonk•7s ago•0 comments

The Norwegian Consumer Council delved into enshittification and how to resist it [video]

https://vimeo.com/1168468796
1•jahala•47s ago•1 comments

Show HN: Tree, but for Token Usage

https://github.com/li-kai/treetok
1•likium•1m ago•0 comments

Ape Coding

https://rsaksida.com/blog/ape-coding/
2•rmsaksida•2m ago•0 comments

Claude Dungeon – Visualize Claude Code sessions as pixel-art dungeon heroes

https://github.com/thousandsky2024/claude-pixel-agent-web
1•simonshishenlsy•2m ago•1 comments

Show HN: Agentic Airport

https://github.com/OvidijusParsiunas/agentic-airport
1•ovisource•3m ago•0 comments

Simple Screw Counter [video]

https://www.youtube.com/watch?v=MkfHD2ShE5s
1•radeeyate•5m ago•0 comments

HN Skins – Read HN in Style with 5 Skins: Cafe, London, Teletype, Terminal, Nox

https://github.com/susam/hnskins
2•susam•5m ago•0 comments

Building with an AI that remembers – A blog by my OpenClaw Assistant

https://janhoon.com/blog/building-with-an-ai-that-remembers/
1•janhoon•6m ago•1 comments

Show HN: Esoteric Single Counter Programming Language

https://af-dev.com/tiny-lang-ui/
1•_adev•9m ago•0 comments

Mastodon Onboarding Workshop

https://termine.di.day/events/0416dee7-cc7f-4e2a-aa94-ff11322daaaa
2•doener•10m ago•0 comments

I wanted to touch grass but the clouds had other plans

https://apps.apple.com/us/app/pingy-cloud-outage-alerts/id6759363978
1•Sayuj01•10m ago•0 comments

I built a CLI tool to detect fake high-res audio and visualize audio spectrum

https://github.com/giorgiogamba/avil
1•giorgiogamba•11m ago•1 comments

Show HN: TheAgentMail – email for AI agents with karma-based spam prevention

https://theagentmail.net/
1•uriva•11m ago•0 comments

Much Will Gas Prices Rise After the Iran Strikes?

https://www.thepricer.org/how-much-will-gas-prices-rise-after-the-iran-strikes/
1•theothersidebac•12m ago•1 comments

Local LLM compresses long prompts before they reach Claude – MCP server

https://github.com/base76-research-lab/token-compressor
1•base76•15m ago•2 comments

Six Into One: The Prisoner File (1984) [video]

https://www.youtube.com/watch?v=5UKga58CYmY
1•olvy0•17m ago•0 comments

Show HN: RTS – A Git-native execution provenance protocol for AI decisions

https://github.com/nobutakayamauchi/RTS
1•nobutaka_y•18m ago•1 comments

AI is making junior devs useless

https://beabetterdev.com/2026/03/01/ai-is-making-junior-devs-useless/
2•beabetterdev•19m ago•0 comments

Search Engine for Vintage Computers

http://frogfind.com/
2•TigerUniversity•21m ago•1 comments

Show HN: Zagora, Distributed fine-tuning platform on mixed GPUs over internet

https://app.zagora.ai
1•miyamotomusashi•21m ago•0 comments

RE#: how we built the fastest regex engine in F#

https://iev.ee/blog/resharp-how-we-built-the-fastest-regex-in-fsharp/
2•exceptione•21m ago•0 comments

Show HN: I'm a teen from Kenya and I built a pretty fast package manager in Rust

https://github.com/v1peridae/vee
3•v1peridae•22m ago•0 comments

The stranger secret: how to talk to anyone – and why you should

https://www.theguardian.com/lifeandstyle/2026/feb/24/stranger-secret-how-to-talk-to-anyone-why-yo...
2•haunter•25m ago•0 comments

America's new era of state-sponsored mining

https://economist.com/briefing/2026/02/26/americas-new-era-of-state-sponsored-mining
2•andsoitis•30m ago•0 comments

How the Federal Government Is Painting Immigrants as Criminals on Social Media

https://www.npr.org/2026/02/27/nx-s1-5720167/trump-ice-immigration-social-media-deportation-dhs-i...
8•TigerUniversity•34m ago•1 comments

The U.S. war on Iran is manifestly unjust

http://edwardfeser.blogspot.com/2026/02/the-us-war-on-iran-is-manifestly-unjust.html
8•danielam•35m ago•0 comments

You Are the Bottleneck

https://zknill.io/posts/you-are-the-bottleneck/
2•zknill•38m ago•0 comments

Een kleine non-profitorganisatie deed wat de FDA niet wilde doen

https://brownstone.org/articles/a-small-nonprofit-did-what-the-fda-would-not/
1•Agnost•39m ago•0 comments

Show HN: CloudPriceCheck – Cloud pricing comparison for 8 providers

https://cloudpricecheck.com/
2•m4sui•40m ago•1 comments