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

Show HN: Threes with Bot Game

https://crates.io/crates/threes-with-bot
2•alfanick•1m ago•0 comments

Thinkslop and all this is true because it is AI

https://substack.com/@fpjunqueira/note/c-289733073
2•fpj•2m ago•1 comments

Learn Nix where it breaks

https://www.labcraft.dev/blog/introducing-labcraft
2•anandsuresh•2m ago•0 comments

Show HN: DreamX-World, Alibaba's new realtime world model

https://twitter.com/reactorworld/status/2074516290442592418
2•hmprt•2m ago•0 comments

Lexxy – A modern rich text editor for Rails

https://lexxy.dev/
2•tortilla•3m ago•0 comments

Show HN: ZeroGate – An API gateway to scale cloud GPUs to zero when idle

https://zerogate.cloud
2•ngarner•3m ago•0 comments

Adding UI for replies between blogs

https://multiline.co/mment/2026/07/adding-ui-for-replies/
2•nate•3m ago•0 comments

Parachute use to prevent death: a review of Randomized Controlled Trials

https://pmc.ncbi.nlm.nih.gov/articles/PMC300808/
2•compiler-guy•5m ago•1 comments

Sites that block AI training crawlers mostly ignore the answer time bots

https://sitedex.dev/insights/robots-txt-2023-war-memorial
2•zeppelin_7•5m ago•0 comments

GPU-accelerated context memory for on-device AI agents on Apple Silicon

https://github.com/christopherkarani/ContextCore
1•christkarani•5m ago•0 comments

Better Auth is joining Vercel

https://better-auth.com/blog/better-auth-joins-vercel
9•sync•5m ago•0 comments

Show HN: Refloow Geo Forensics 1.4 – Local EXIF extraction and timeline mapping

https://github.com/Refloow/Refloow-Geo-Forensics
1•refloow•6m ago•0 comments

Reversible Computing

https://en.wikipedia.org/wiki/Reversible_computing
1•tristenharr•8m ago•0 comments

Show HN: Interactive Short Story Collection

https://jordanjordanjordan.com/
1•jordan9001•8m ago•0 comments

WhatsApp Business for iOS Crashes After 16 Seconds When Companion Is Connected

https://granot.io/whatsapp-business-for-ios-sucks/
1•tomgs•10m ago•0 comments

Show HN: DoodleMeme – Animate Hand Drawings Without Generative AI

https://doodlemate.com/meme
1•hjessmith•10m ago•0 comments

After defying Pope Leo and causing schism, SSPX defends its actions

https://www.ncronline.org/vatican/after-defying-pope-leo-and-causing-schism-sspx-defends-its-actions
1•firasd•10m ago•0 comments

Classical computing, quantum computing, and Shor's factoring algorithm (1999)

https://www.alphaxiv.org/abs/quant-ph/9903008
1•measurablefunc•11m ago•0 comments

Show HN: Reins – let coding agents drive your real, logged-in browser

https://reins.karnstack.com
2•karngyan•13m ago•0 comments

Landauer's Principle

https://en.wikipedia.org/wiki/Landauer%27s_principle
1•tristenharr•13m ago•0 comments

Phonebloks: A global campaign to bring to life a modular phone to reduce e-waste

https://www.onearmy.earth/project/phonebloks
1•Jomal_HN•15m ago•0 comments

I Bought a Sony Walkman

https://82mhz.net/posts/2026/07/i-bought-a-sony-walkman/
1•edward•16m ago•0 comments

If an AI can do no harm, then it can do no good

https://higashi.blog/2026/06/26/safety/
2•yuedongze•17m ago•0 comments

Buzzword Driven Development: Stop Talking About the CAP theorem

https://nextpath.substack.com/p/stop-talking-about-the-cap-theorem
3•code_pig•19m ago•0 comments

Keet – Encrypted peer to peer messaging

https://keet.io/
2•rickcarlino•19m ago•0 comments

Why we built yet another Postgres connection pooler

https://pgdog.dev/blog/why-yet-another-connection-pooler
1•levkk•21m ago•0 comments

Probes.dev Is Released

https://limeleaf.coop/blog/probes-is-released/
2•blainsmith•21m ago•0 comments

Together for a Healthier Clippy

https://blog.rust-lang.org/inside-rust/2026/07/06/unite-for-clippy/
1•birdculture•21m ago•0 comments

Rootless Docker and Its Hidden Security Trade-Offs

https://www.kenmuse.com/blog/rootless-docker-and-its-hidden-security-trade-offs/
1•speckx•23m ago•0 comments

A freelancer marketplace for international projects

https://freelancer.svoxx.com/int/en
1•kilincarslan•23m ago•0 comments