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

Comments

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

I created a tool to roast your landing page

https://landkit.pro/audit
1•nikhonit•22s ago•0 comments

Show HN: A full-scale build simulator for Dreadmyst (Action RPG)

https://dreadmystbuildsimulator.com
1•18272837023•1m ago•0 comments

Lsferreira42/figlet-go: A figlet Golang rewrite

https://github.com/lsferreira42/figlet-go
1•lsferreira42•1m ago•0 comments

Chinese woman discovers her iPhone X can be unlocked by her friend's face (2017)

https://mothership.sg/2017/12/iphone-x-asians-look-the-same/
1•thunderbong•3m ago•0 comments

Fill in a lean canvas nicely in the browser and download it

https://cluelessuk.github.io/lean-canvas-ui/
1•h0h0h0h0111•3m ago•0 comments

Ask HN: How do you prevent AI agents from going rogue in production?

1•techbuilder4242•3m ago•0 comments

AI Analyzes Faces to Measure Pain Levels

https://spectrum.ieee.org/machine-learning-measure-pain-surgery
2•JeanKage•5m ago•0 comments

Show HN: FlexList – A global leaderboard where you pay to own your city

https://flexlist.app
2•frodothebrave•6m ago•1 comments

EmbodIOS - AI inference as the operating system (3.5s cold start)

https://github.com/dddimcha/embodiOS
2•dddimcha•12m ago•0 comments

Birth Lottery

https://www.givingwhatwecan.org/birth-lottery
1•gmays•12m ago•1 comments

InvokeAI Commercial Platform Shuts Down, Open-Source Project Continues

https://softuts.com/invokeai-commercial-platform-shuts-down-open-source-project-continues/
2•XCSme•12m ago•1 comments

Salesforce, SAP, or ServiceNow: Which Is Most Ripe for Disruption?

1•Saurabh_Kumar_•13m ago•0 comments

90% of Cheese Contains a Pfizer-Developed GMO Ingredient–Here's What That Means

https://drgator.substack.com/p/90-of-cheese-contains-a-pfizer-developed
1•nateb2022•14m ago•0 comments

Show HN: AionUi – Open-Source Cowork for Claude Code, Gemini CLI, Codex and More

https://github.com/iOfficeAI/AionUi
2•waili•14m ago•0 comments

Show HN: FastScheduler – Decorator-first Python task scheduler, async support

https://github.com/MichielMe/fastscheduler
1•michielme•15m ago•0 comments

Ask HN: Salesforce, SAP, or ServiceNow: Which Is Most Ripe for Disruption?

1•Saurabh_Kumar_•15m ago•1 comments

Git Subtree and Other Tips for Migrating a Repo

https://spin.atomicobject.com/git-subtree-migrating-repo/
2•philk10•16m ago•0 comments

Password Storage

https://ciamweekly.substack.com/p/password-storage
1•PretzelFisch•17m ago•0 comments

Citigroup set to cut about 1k jobs this week

https://www.reuters.com/sustainability/citigroup-is-set-cut-about-1000-jobs-bloomberg-news-report...
1•geox•17m ago•0 comments

Show HN: StatefulSet Backup Operator v0.0.3–Configurable snapshots, Redis tested

https://github.com/federicolepera/statefulset-backup-operator
1•lep_qq•18m ago•0 comments

Node.js Tuesday, January 13, 2026 Security Releases

https://nodejs.org/en/blog/vulnerability/december-2025-security-releases
2•syvanen•19m ago•0 comments

Show HN: DSAT – Data Subject Access Toolkit

https://codeberg.org/erkinalp/dsat
2•anticensor•19m ago•0 comments

Software Is Mostly All You Need

https://softwarefordays.com/post/software-is-mostly-all-you-need/
4•jbmilgrom•19m ago•0 comments

Pentagon is embracing Musk's Grok AI chatbot as it draws global outcry

https://www.cnbc.com/2026/01/13/pentagon-is-embracing-musks-grok-ai-chatbot-as-it-draws-global-ou...
1•teekert•20m ago•0 comments

The rise (and future fall) of Discord (2024)

https://slugcat.systems/post/24-12-12-the-rise-and-future-fall-of-discord/
1•birdculture•22m ago•0 comments

Apple and Google's AI partnership announcement spells AI wrong

2•pnrth•22m ago•0 comments

Show HN: OneView – Autopilot for Marketing Data

https://oneviewhub.com/
2•lunarrocket•23m ago•0 comments

Overflow: React Flow component library for user-friendly diagrams and flows

https://github.com/synergycodes/overflow-ui
2•diagrammode•24m ago•1 comments

Show HN: Analyze JUnit test files in the browser

https://reportoire.kaafihai.com
1•azan-n•25m ago•1 comments

Hatch: A Modern Approach to Python Project Management

https://hatch.pypa.io/1.16/
1•lailaDar•26m ago•2 comments