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

Comments

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

Millions of Locations for Thousands of Brands

https://tech.marksblogg.com/alltheplaces.html
1•marklit•48s ago•0 comments

Microservices Should Form a Polytree

https://bytesauna.com/post/microservices
1•mapehe•1m ago•1 comments

Married millennials, here comes the crypto divorce cliff

https://www.cnbc.com/2025/12/07/millennials-bitcoin-crypto-divorce-law.html
1•em3rgent0rdr•3m ago•0 comments

IBM nears $11B confluent deal

https://www.reuters.com/technology/ibm-nears-roughly-11-billion-deal-confluent-wsj-reports-2025-1...
1•hulahoof•5m ago•1 comments

Chinese phonemakers seize on Apple's AI struggles

https://www.ft.com/content/5bfaf5f3-c92a-41e1-81a6-c065a1bc61c2
1•ashishgupta2209•8m ago•0 comments

Show HN: Opinionated Cloudflare D1 and Kysely toolkit

https://www.npmjs.com/package/d1-kyt
1•tundrax•8m ago•0 comments

Samsung's recent AI ad spam crushes creativity, and the irony is stunning

https://www.sammobile.com/opinion/samsung-recent-ai-ad-spam-crushes-creativity-and-the-irony-is-s...
1•austinallegro•10m ago•0 comments

Rope Trick Effect

https://en.wikipedia.org/wiki/Rope_trick_effect
2•harryday•14m ago•0 comments

Artificial intelligence research has a slop problem

https://www.theguardian.com/technology/2025/dec/06/ai-research-papers
2•kefabean•15m ago•0 comments

Going direct: notes on Eli Lilly at a trillion

https://atelfo.github.io/2025/12/07/going-direct.html
1•docdeek•16m ago•0 comments

Justin Bieber dislikes Apple's dictate button placement

https://twitter.com/justinbieber/status/1997125645437194682
1•petepete•21m ago•0 comments

Show HN: Leetwrap – A "Spotify Wrapped" for LeetCode

https://www.leetwrap.com/
2•kumarsashank•25m ago•0 comments

Show HN: Preflight – Replace shell validation scripts in Dockerfiles

https://github.com/vertti/preflight
1•vertti•33m ago•0 comments

Speech and Language Processing (3rd ed. draft)

https://web.stanford.edu/~jurafsky/slp3/
1•atomicnature•35m ago•0 comments

Show HN: Crier – Push notifications via TCP or MQTT (no public IP needed)

https://github.com/skorotkiewicz/crier
1•modinfo•36m ago•0 comments

Proposed Link Between Quantum-Corrected Geodesics and Dark-Matter-Like Phenomena

https://zenodo.org/records/17848182
1•Jascon71•39m ago•0 comments

The Path to Mojo 1.0

https://www.modular.com/blog/the-path-to-mojo-1-0
3•chenzhekl•42m ago•0 comments

A Clever Approach to AI Drawing I Accidentally Discovered – Bear. Best

https://bear.best/en/blog/a-clever-approach-to-ai-drawing/
2•BearBest•44m ago•0 comments

BusyBox-Only Linux

https://github.com/chirsz-ever/busybox-linux
1•chirsz•45m ago•0 comments

Versioning Events Without Breaking Everything

https://docs.eventsourcingdb.io/blog/2025/12/08/versioning-events-without-breaking-everything/
1•goloroden•46m ago•0 comments

IBM nears $11B deal to acquire Confluent

https://finance.yahoo.com/news/ibm-nears-roughly-11-billion-031139352.html
3•theanonymousone•49m ago•1 comments

Show HN: CatalystAlert – Free biotech catalyst calendar (985 companies tracked)

https://catalystalert.io
7•nykodev•49m ago•5 comments

Show HN: Brick Starter – .NET SaaS starter kit to ship production apps faster

https://www.brickstarter.net
1•plakhlani2•51m ago•1 comments

Russian authorities have imposed restrictions on FaceTime

https://apnews.com/article/russia-internet-crackdown-facetime-restrictions-06301be480510b18ae0203...
2•chmaynard•52m ago•0 comments

Kinesis Advantage2

https://danishpraka.sh/posts/kinesis-advantage2/
1•prakashdanish•1h ago•0 comments

Show HN: Peargent – A Simple Python Framework for Building AI Agents

https://github.com/Quanta-Naut/peargent
1•Quanta-Naut•1h ago•1 comments

Indian boy, aged 3, becomes youngest rated chess player in history

https://www.nytimes.com/athletic/6869534/2025/12/07/youngest-chess-player-age-india/
2•NewCzech•1h ago•1 comments

Finnix

https://en.wikipedia.org/wiki/Finnix
3•fuzztester•1h ago•1 comments

Fifty Years of Retracted Medical Publications from 1975 to 2024

https://jkms.org/DOIx.php?id=10.3346/jkms.2025.40.e300
1•XzetaU8•1h ago•0 comments

Apple Taps Meta Lawyer as General Counsel in Latest Shake-Up

https://www.bloomberg.com/news/articles/2025-12-04/apple-taps-top-meta-lawyer-as-general-counsel-...
2•mgh2•1h ago•1 comments