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•1y ago

Comments

zoezoezoezoe•1y 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•1y 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.

Church Encoding, Parametricity, and the Yoneda Lemma

https://blog.wybxc.cc/blog/parametricity/
1•g0xA52A2A•4m ago•0 comments

Null Linux

https://github.com/Duck25543/Null-Linux
1•PvsLH102•6m ago•0 comments

Whimsical Animations

https://whimsy.joshwcomeau.com
1•vismit2000•7m ago•0 comments

Texas AG sues Meta over claims that WhatsApp doesn't provide end-to-end encrypt

https://arstechnica.com/security/2026/05/texas-ag-sues-meta-over-claims-that-whatsapp-doesnt-prov...
1•joozio•9m ago•0 comments

After Automation

https://every.to/p/after-automation
1•jibcage•18m ago•0 comments

Spanish Court Declines to Fine NordVPN over LaLiga Piracy Blocking Order

https://torrentfreak.com/spanish-court-declines-to-fine-nordvpn-over-laliga-piracy-blocking-order/
2•gslin•19m ago•0 comments

The Best Windows is Linux

https://lunduke.substack.com/p/the-best-windows-is-linux
2•gargan•25m ago•0 comments

The just-say-no engineer was a ZIRP phenomenon

https://www.seangoedecke.com/the-just-say-no-engineer-was-a-zirp-phenomenon/
1•vismit2000•26m ago•0 comments

High-Throughput Chips for LLMs

https://matx.com/
1•consumer451•28m ago•0 comments

Denuvo game cracked on day 1 of launch

https://pastebin.com/jQjvNrvA
2•sensanaty•29m ago•0 comments

Parsing IPv6 Addresses Crazily Fast with AVX-512

https://lemire.me/blog/2026/05/23/parsing-ipv6-addresses-crazily-fast-with-avx-512/
2•0xedb•29m ago•0 comments

Show HN: Brev – A frictionless Android note taking app

https://play.google.com/store/apps/details?id=com.shkurta.brev&hl=en_US
1•Klaudjo_shkurta•35m ago•0 comments

Layoffs Hitting Zalando?

https://old.reddit.com/r/cscareerquestionsEU/comments/1tkx5ll/layoffs_hitting_zalando/
2•theanonymousone•35m ago•0 comments

The International Space Station is leaking (again)

https://arstechnica.com/space/2026/05/uh-oh-the-international-space-station-is-leaking-again/
1•jnord•36m ago•0 comments

AI is getting pricey, but relief is coming, but not for you

https://www.theregister.com/ai-ml/2026/05/21/ai-is-getting-pricey-but-relief-is-coming-but-not-fo...
1•jnord•37m ago•1 comments

ExtendDB – The DynamoDB API, everywhere you run code

https://extenddb.org/
2•0xedb•39m ago•1 comments

New RFC Editor Website

https://www.rfc-editor.org/
1•jerleth•39m ago•0 comments

Former US execs plead guilty to aiding tech support scammers

https://www.bleepingcomputer.com/news/security/former-us-execs-plead-guilty-to-aiding-tech-suppor...
2•jnord•41m ago•0 comments

Rubish: A Unix shell written in pure Ruby

https://github.com/amatsuda/rubish
3•winebarrel•42m ago•0 comments

Ask HN: Is $300/HR too low these days for custom full stack?

2•noduerme•42m ago•0 comments

UK economic catastrophe unless it adapts to young people rewired by smartphones

https://news.sky.com/story/uk-faces-economic-catastrophe-unless-it-adapts-to-young-people-rewired...
3•austinallegro•46m ago•1 comments

Pip 26.1 Ships Dependency Cooldowns and Experimental Lockfile Support

https://www.infoq.com/news/2026/05/pip-261-dependency-cooldowns/
2•OutOfHere•53m ago•0 comments

Show HN: TruLayer – tracing, evals, and a control loop for production LLMs

https://trulayer.ai/
2•trulayer•53m ago•0 comments

The Software Coordination Tax: Why Your 40-Engineer Team Is Shipping Like 25

https://www.forbes.com/councils/forbestechcouncil/2026/05/20/the-software-coordination-tax-why-yo...
2•RyeCombinator•1h ago•0 comments

Exploring Ref Qualifiers in C++

https://meetingcpp.com/blog/items/Exploring-ref-qualifiers-in-Cpp.html
3•signa11•1h ago•0 comments

Why are there keys on my messenger app that I don't recognize

2•ttim•1h ago•0 comments

The uno reverse public license

https://github.com/Zuhaitz-dev/URPL
2•anticensor•1h ago•0 comments

Open-source living-room entertainment system, with pretty UI made in Electron

https://github.com/charnam/ClasmeraSpace
3•charnam•1h ago•2 comments

Riyadh Leads Global Tech Growth as Cyprus Becomes Europe's Crisis Safe Haven

https://www.startupblink.com/startupecosystemreport
2•Sam6late•1h ago•1 comments

AI-Declaration.md

https://github.com/DimwitLabs/AI-DECLARATION.md
2•rapiz•1h ago•0 comments