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

Visual Heroin: How algorithmic feeds hijack cognition and executive focus

1•TheGibberishNot•57s ago•0 comments

Fuzzy terminal manager to pick, configure, and run local GGUF model

https://github.com/skorotkiewicz/run-model
1•modinfo•1m ago•0 comments

A startup claims it's found a drug to make your blood young

https://www.technologyreview.com/2026/08/27/1143037/startup-claims-its-found-a-drug-to-make-your-...
1•joozio•1m ago•0 comments

Tips for giving S-tier demos

https://newsletter.posthog.com/p/how-to-demo
1•fagnerbrack•2m ago•0 comments

Grimm's Law

https://en.wikipedia.org/wiki/Grimm%27s_law
1•ogogmad•6m ago•0 comments

Open-source vacuum robot cleaner

https://github.com/makerspet/oomwoo
1•jinqueeny•10m ago•0 comments

Agent Swarms Are a Distributed Systems Problem

https://www.trychroma.com/engineering/transactions
1•handfuloflight•12m ago•0 comments

Norway's King Harald dies aged 89

https://www.bbc.com/news/articles/clykn5p5172o
4•punnerud•13m ago•0 comments

Game over for Unauthorized AI Performances: The Sag-Aftra Video Game Strike

https://sites.suffolk.edu/jhtl/2025/10/30/game-over-for-unauthorized-ai-performances-the-sag-aftr...
1•Bluestein•13m ago•0 comments

America's Never-Ending Battle Against Flesh-Eating Worms

https://www.theatlantic.com/science/archive/2020/05/flesh-eating-worms-disease-containment-americ...
1•Bluestein•16m ago•0 comments

Show HN: KIIP Study – exam practice for Korea's immigration test (16 languages)

https://www.kiipstudy.com
1•sangkwun•17m ago•1 comments

Show HN: FnScribe – Open-source, offline dictation for macOS

https://github.com/AlgorithmicResearchGroup/fnscribe
2•modagent•17m ago•2 comments

The cause of most wildfires? People

https://www.npr.org/2026/08/27/nx-s1-5944328/the-real-cause-of-most-wildfires-people
1•andsoitis•17m ago•0 comments

Tencent Hy4 Preview

https://openrouter.ai/tencent/hy4-preview
2•theanonymousone•18m ago•0 comments

smarchFanny

https://github.com/S-March/stepNsnackFannyPack_Public
1•EndXA•18m ago•0 comments

Over 160 staff at Irish 'unicorn' firm Cubic3 told their jobs are at risk

https://www.thejournal.ie/cubic3-layoffs-ireland-7144462-Aug2026/
2•austinallegro•22m ago•1 comments

Show HN: Free tool that turns market research into a personal branding strategy

https://www.intelcue.ai/tools/personal-branding-strategy-builder
1•intelcue•26m ago•0 comments

Singapore Switches on Biological Computing Rack with Living Human Neurons

https://www.techrepublic.com/article/news-biological-computing-rack-apac-singapore/
1•the-mitr•28m ago•1 comments

Luanti removed from Google Play due to baseless AI copyright notice

https://blog.luanti.org/2026/08/27/luanti-dmca-tracer-ai/
3•miniBill•29m ago•0 comments

Challenges when writing gren-format

https://gilramir.github.io/gren-format-lib/grenFormatChallenges.html
1•Skinney•30m ago•0 comments

Oj: your Rust native replacement for Vite

https://rapha.land/introducing-oj/
1•flashblaze•32m ago•0 comments

AI writing has begun to appear on the opinion pages

https://www.semafor.com/article/08/26/2026/ai-writing-has-already-begun-to-appear-on-oped-pages
1•andsoitis•33m ago•0 comments

Hy4 Preview

https://hy.tencent.ai/research/hy4-preview
3•cmitsakis•38m ago•1 comments

Hy4 Preview

https://huggingface.co/tencent/Hy4-preview
5•yogenpro•39m ago•0 comments

We ran X (Twitter) ads for 4 months and here are the results

4•Daniel-Pan•39m ago•1 comments

Talk Is Cheap. Code Is Cheap. Show Me the Source

https://idlip.in/posts/show-me-source/
2•rapnie•45m ago•0 comments

Wage Against The Machine – each country's AI task purchasing power

https://watm.ddyo.dev/
2•danr4•46m ago•0 comments

A Looming Rare Earth Shortage Threatens Critical Tech

https://spectrum.ieee.org/rare-earth-shortage
4•JeanKage•49m ago•2 comments

I Had Claude and Codex Rewrite the Same App. The One with Better Architecture

https://medium.com/@yalovoy/i-had-claude-and-codex-rewrite-the-same-app-the-one-with-better-archi...
3•zero-ground-445•49m ago•1 comments

Show HN: Classroom Timer – Free Online Countdown for Teachers

https://classroomtimers.app
3•doublez85•53m ago•0 comments