frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

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

A Self-Spreading Supply Chain Attack Compromises TanStack NPM Packages

https://www.stepsecurity.io/blog/mini-shai-hulud-is-back-a-self-spreading-supply-chain-attack-hit...
1•bpierre•1m ago•0 comments

Apple Releases iOS 26.5 and iPadOS 26.5 with End-to-End Encrypted RCS

https://www.macrumors.com/2026/05/11/apple-releases-ios-26-5/
1•JumpCrisscross•2m ago•0 comments

GM cutting up to 600 white-collar jobs, even as it seeks tech talent

https://www.detroitnews.com/story/business/autos/general-motors/2026/05/11/gm-to-cut-some-tech-jo...
1•littlexsparkee•4m ago•0 comments

Launching on Product Hunt Tonight

https://www.stackgraveyard.dev/
1•tlseternal•5m ago•0 comments

Show HN: Scholr – search 200M+ academic papers with citation-grounded synthesis

https://www.tryscholr.com/
1•JosephB07•6m ago•0 comments

We are not going to agree on AI

https://idiallo.com/blog/we-are-not-going-to-agree-on-ai
1•foxfired•7m ago•0 comments

Ask HN: What happens when eventually all E2E mess. apps removed from app stores?

1•kingleopold•7m ago•0 comments

Met Introduces Hi-Def 3D Scans of Dozens of Historical Art Objects

https://www.thisiscolossal.com/2026/03/metropolitan-museum-of-art-3d-models-art-history/
1•bookofjoe•8m ago•0 comments

Open-source endpoint detection engine for Windows and Linux

https://github.com/Karib0u/rustinel
1•nhatcher•9m ago•0 comments

Marco Polo: Finding a friend with only distance and motion

https://www.jackhogan.me/blog/marco-polo
1•amy1173•11m ago•0 comments

Searching over Session Transcripts > MEMORY.md

https://github.com/edwarddgao/agent-traces
1•edwarddgao•11m ago•1 comments

VGA memory access is complicated

https://www.os2museum.com/wp/learn-something-old-every-day-part-xxi-vga-memory-access-is-complica...
1•bananaboy•13m ago•0 comments

Natural Language Autoencoders Produce Unsupervised Explanations LLM Activation

https://transformer-circuits.pub/2026/nla/
1•Anon84•13m ago•0 comments

The Dome: A Simple Violation of Determinism in Newtonian Mechanics

https://sites.pitt.edu/~jdnorton/Goodies/Dome/index.html
2•antiquark•21m ago•0 comments

Show HN: I built an MCP server for narrative-driven trading intelligence

2•anish_mitta•23m ago•0 comments

Show HN: Origami – A simple workspace-oriented terminal manager

https://tryorigami.app
2•uniqid•24m ago•0 comments

Porn website at center of CNN investigation into sexual abuse taken offline

https://www.cnn.com/2026/05/08/europe/porn-site-motherless-taken-down-dutch-authorities-intl
3•Bender•25m ago•0 comments

Microsoft doesn't want you to know this [video]

https://www.youtube.com/watch?v=iuIdBfjL62s
2•janalsncm•26m ago•0 comments

Devon

https://grimfandango.substack.com/p/devon
2•lastdong•32m ago•0 comments

LinkLens: Protect Yourself from Clickbait

https://chromewebstore.google.com/detail/linklens/dbfidmikilfcnkngenffkinmknoblaap
2•philstahlfeld•33m ago•0 comments

After banning foreign routers, FCC says existing ones can get updates until 2029

https://arstechnica.com/tech-policy/2026/05/fcc-slightly-relaxes-foreign-router-ban-allows-softwa...
6•Bender•33m ago•1 comments

Chinese Powev Enters DDR5 Market with Up to 64 GB Udimm, Sodimm, and Rdimm

https://www.techpowerup.com/348936/chinese-powev-enters-ddr5-market-with-up-to-64-gb-udimm-sodimm...
6•SockThief•33m ago•0 comments

A Caddy Cert Expired Because Systemd-Resolved Was Selectively Broken

https://rant.mvh.dev/a-caddy-cert-expired-because-systemd-resolved-was-selectively-broken/
3•PaulHoule•34m ago•0 comments

Closure of Radio 4 on Long Wave (LW)

https://www.bbc.co.uk/reception/work-warning/news/radio4lw
4•austinallegro•37m ago•0 comments

A brain reward circuit inhibited by next-generation weight-loss drugs in mice

https://www.nature.com/articles/s41586-026-10444-4
2•Bender•38m ago•0 comments

I Disagree with Paul Graham

https://mrmarket.bearblog.dev/i-disagree-with-paul-graham/
2•seltzerboys•38m ago•0 comments

Show HN: Route optimization API that solves fleet planning as a single problem

https://demo.vepathos.com
1•pantherolive•39m ago•0 comments

PostHog Code

https://posthog.com/code
1•smitec•46m ago•0 comments

When readers would rather listen

https://blog.keyvan.net/p/ai-voiced-narration-for-articles
1•k1m•46m ago•0 comments

An Ice Cold Take on CI Config Systems

https://v5.chriskrycho.com/notes/an-ice-cold-take-on-ci-config-systems/
2•mooreds•47m ago•0 comments