frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Ask HN: Which function definition keyword do you prefer, def or fn?

1•winwang•1y ago
I'm curious about what people think of `def` vs `fn`, two short keywords for starting function definitions.

...Or maybe we should subscribe to the church of `df`, haha.

Comments

sitkack•1y ago
def could be for lots of things, fn is for functions. I don't think it matters much as long as you have one. C would have been so much easier to parse. Just copy Zig or Rust.
butlersean•1y ago
def means define, could be used to define all kinds of things

fn isnt a legitimate short form of function

fun doesnt work because of the amusement factor

func is the only alternative we have left

sitkack•1y ago
How about unicode or emojis?

These don't have the full fidelity as hn scrubs emojis

add = (a, b) -> a + b

a, b ⟹ a + b

λ add(a, b): ↪ a + b

johncoltrane•1y ago
"def" is too generic.

"fn" is too cryptic.

"function" is better than the two.

MultifokalHirn•1y ago
Agreed

Correlated randomness in Slay the Spire 2

https://tck.mn/blog/correlated-randomness-sts2/
1•rdmuser•2m ago•0 comments

Brick: SOTA LLM Routing

https://arxiv.org/abs/2606.13241
1•FrancescoMassa•4m ago•0 comments

A Chinese rocket breaks apart dangerously close to the Starlink constellation

https://arstechnica.com/space/2026/06/a-chinese-rocket-breaks-apart-dangerously-close-to-the-star...
1•rbanffy•4m ago•0 comments

Florida lawsuit accuses TikTok of violating state's child social media ban

https://www.theguardian.com/us-news/2026/jun/15/florida-sues-tiktok-teen-social-media-access-law
1•beardyw•4m ago•0 comments

Papers from the Lost Culture of Array Languages (2011)

https://prog21.dadgum.com/114.html
1•tosh•5m ago•0 comments

France's sovereignty push can't escape the Microsoft gravity well

https://www.theregister.com/on-prem/2026/06/16/frances-digital-sovereignty-push-is-struggling-to-...
2•Timofeibu•6m ago•1 comments

Notes from Tired Egyptian Whose Job Is Explaining That Humans Built the Pyramids

https://www.mcsweeneys.net/articles/notes-from-a-tired-egyptian-guy-whose-job-is-explaining-that-...
2•Geekette•13m ago•0 comments

Show HN: Hyperbox- $40/month Mac mini rentals

https://hyperbox.sh
1•Areibman•15m ago•0 comments

Show HN: ProData AI – 14 MCP tools for automated data science

https://mcpize.com/mcp/prodata-ai
2•varunwalekar•16m ago•0 comments

ML research datasets from ArXiv and Semantic Scholar (JSONL, quality-scored)

https://huggingface.co/fineset-io
1•dangerlego5•18m ago•1 comments

Trinket.io shutting down, so we saved it and hosted it a trinket.strivemath.org

https://trinket.strivemath.org/
3•apulkit6•18m ago•1 comments

My unvarnished guide to solution engineering

https://maxhalford.github.io/blog/solution-engineering-advice/
1•AdilZtn•19m ago•0 comments

Writing a browser-use agent from scratch – Part 1/3 – The Capture

https://pdufour.substack.com/p/writing-a-browser-use-agent-from
1•thunderbong•19m ago•0 comments

The fight over Claude Mythos 5

https://www.theverge.com/ai-artificial-intelligence/950412/anthropic-trump-adminstration-claude-m...
1•Shank•19m ago•0 comments

What the CEO Wants You to Know

https://commoncog.com/what-the-ceo-wants-you-to-know/
1•simonebrunozzi•20m ago•0 comments

How We Built a High-Performance Factor Evaluation Framework

https://medium.com/@DolphinDB_Inc/high-performance-factor-evaluation-with-dolphindb-23bb6954503f
2•Polly_Liu•23m ago•0 comments

Feds freaked over Fable 5 after simple 'fix this code' prompt, not jailbreak

https://www.theregister.com/security/2026/06/15/feds-freaked-over-fable-5-after-simple-fix-this-c...
3•_tk_•23m ago•0 comments

Mike Acton: Convex Primitive Collision Detection – Reference and LLM-Optimized

https://github.com/macton/differentiable-collisions-optc
2•thdr•23m ago•0 comments

Dutch children are unusually happy and healthy. Because of this walking ritual?

https://www.theguardian.com/lifeandstyle/2026/jun/16/dutch-children-unusually-happy-healthy-avond...
2•monkey_monkey•25m ago•0 comments

Tensordyne Napier AI Processor Announced with Logarithmic Math

https://www.servethehome.com/tensordyne-napier-ai-processor-announced-with-logarithmic-math/
1•lumpa•30m ago•0 comments

South Korea Politicians Wants AI Profit Sharing

https://www.gadgetreview.com/south-korea-floats-citizen-dividend-ai-profit-sharing-as-tech-stocks...
2•thomasfl•32m ago•1 comments

GPU Is the New Oil

https://xificurc.github.io/blog/gpu-is-the-new-oil/
1•comma_at•33m ago•0 comments

We Built a Real-Time Money Flow Monitoring System

https://medium.com/@DolphinDB_Inc/tracking-smart-money-in-real-time-building-a-minute-level-capit...
2•CrazyTomato•33m ago•0 comments

Commodore Releases Flip Phone

https://commodore.net/why-a-flip-phone/
6•bartekrutkowski•34m ago•0 comments

The Fable 5 Export Controls Harm US Cyber Defense

https://simonwillison.net/2026/Jun/16/fable-5-export-controls/
1•lumpa•34m ago•0 comments

Nubase – an open-source back end/deploy layer for AI-written apps

https://github.com/OtterMind/Nubase
2•jipengfei1016•37m ago•0 comments

Commodore Callback

https://commodore.net/callback/
8•peterkelly•40m ago•0 comments

Nockchain: A protocol for verifiable Compute Networks

https://nockchain.org/
2•MrBuddyCasino•41m ago•0 comments

Show HN: Opencom – an open-source Intercom alternative given the Salesforce deal

https://opencom.dev
4•jackjayd•43m ago•0 comments

Show HN: Cultivation World Simulator

https://github.com/4thfever/cultivation-world-simulator
2•bridge2333•43m ago•0 comments