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.

Ask HN: How much should a bootstrapper spend to give an idea a fair shot?

1•shadabshs•26s ago•0 comments

Levi: Beating GEPA/OpenEvolve/AlphaEvolve at a fraction of the cost

https://github.com/ttanv/levi
2•ttanveer•2m ago•0 comments

Show HN: We benchmarked 3 AI video detection APIs on 190 videos

https://game.defakes.com/feed
1•ortalboh•2m ago•1 comments

Show HN: P2PCLAW – I built a decentralized research network where AI agents

1•FranciscoAngulo•3m ago•0 comments

Performance Leaderboard for News Sites

https://webperf.xyz/
1•thunderbong•3m ago•0 comments

Beach Spectres

https://beachspectres.com/
1•ColinWright•3m ago•0 comments

Building an LSP Server with Rust is surprisingly easy and fun

https://codeinput.com/blog/lsp-server
1•codeinput•3m ago•0 comments

The AI Spending Flip

https://www.axios.com/2026/03/18/ai-enterprise-revenue-anthropic-openai
1•boh•4m ago•0 comments

Ask HN: The sites gaming Kagi Small Web are ruining the experience

1•chris_money202•6m ago•0 comments

EverQuest lawsuit settlement threats $3.5M in damages against emulator operators

https://massivelyop.com/2026/03/18/everquest-lawsuit-reaches-settlement-with-threat-of-3-5m-in-da...
1•speckx•7m ago•0 comments

Sucker: My Year as a Degenerate Gambler

https://www.theatlantic.com/magazine/2026/04/online-sports-betting-app-addiction/686061/
1•dbl000•8m ago•0 comments

First and Lego Education Partnership Update

https://community.firstinspires.org/first-lego-education-partnership-update
1•jchin•8m ago•0 comments

Virtual Twin Could One Day Save Your Life

https://spectrum.ieee.org/living-heart-project-virtual-twins
1•Brajeshwar•11m ago•0 comments

Agents have a human personality problem

https://dheer.co/agent-personality/
1•bushido•11m ago•0 comments

The developers who aren't letting AI push them out

https://leaddev.com/ai/meet-the-software-engineers-who-arent-letting-ai-push-them-out
1•birdculture•12m ago•0 comments

American Diner Gothic – the weird soul of placeless America

https://www.thenewatlantis.com/publications/american-diner-gothic
1•GranularRecipe•12m ago•0 comments

Using Claude Code+ API is better and cheaper than products like lovable

1•johnnyfeng•13m ago•0 comments

One Hundred Years in the U.S. Stock Markets

https://papers.ssrn.com/sol3/papers.cfm?abstract_id=6438198
1•Luc•14m ago•1 comments

The RAM stick is dying, and the replacement is something most have never seen

https://www.xda-developers.com/the-ram-stick-is-dying-and-the-replacement-is-something-most-pc-bu...
4•speckx•14m ago•1 comments

Show HN: Open Source CRM List

https://github.com/sneg55/awesome-open-source-crm
1•sneg55•15m ago•0 comments

Maybe version ranges are a good idea after all?

https://neilmadden.blog/2026/03/19/maybe-version-ranges-are-a-good-idea-after-all/
1•wstrange•16m ago•0 comments

My favorite thing to do with AI doesn't have a label

https://daniel.do/article/my-favorite-thing-to-do-with-ai
1•dimmke•17m ago•0 comments

Q.ANT Hits Full Production Capacity for Photonic AI Processors

https://www.eetimes.com/q-ant-hits-full-production-capacity-for-photonic-ai-processors/
1•JoachimS•18m ago•0 comments

My job is to make things shitty (video)

https://substack.com/@meaghanwilsonanastasios/note/c-223191161
1•savolai•18m ago•1 comments

The Tau256 Block Cipher

https://github.com/secworks/tau256
1•JoachimS•19m ago•0 comments

We launched a lead magnet and got 300 people interested in 24 hours

3•gavinzaentz•19m ago•1 comments

Show HN: Open-source synthetic bank statements for testing parsers

1•Maesh•20m ago•0 comments

Facing US oil blockade, Cuban man powers car with charcoal

https://www.reuters.com/business/energy/facing-us-oil-blockade-cuban-man-powers-car-with-charcoal...
1•carlos_rpn•21m ago•2 comments

Show HN: Leviathan-crypto – WebAssembly cryptography library for TypeScript

https://github.com/xero/leviathan-crypto
1•vitonsky•22m ago•0 comments

Answer Engine Optimization

https://juliasolorzano.com/blog/2026/03/16/answer-engine-optimization/
2•speckx•23m ago•0 comments