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

I created an extension for Claude that shares context on how you work

https://github.com/stubbleapp/Stubble
1•satay_chicken31•32s ago•0 comments

A multi-agent system for automating scientific discovery

https://www.nature.com/articles/s41586-026-10652-y
1•Timofeibu•1m ago•0 comments

Chewing gum restores dad's taste and smell years after Covid

https://discover.swns.com/2026/05/chewing-gum-restores-dads-taste-and-smell-years-after-covid/
1•speckx•2m ago•0 comments

Show HN: From one Claude agent to a fleet – in five small steps

1•sermakarevich•2m ago•0 comments

Sony Flamingo - The Coolest Record Player Ever Made

https://obsoletesony.substack.com/p/the-coolest-record-player-ever-made
1•reconnecting•3m ago•0 comments

A permissively licensed Vita FPGA Architecture in only 380 lines of Verilog

https://github.com/VitaSetLLC/VitaOS-Libre
1•VitaSetLLC•4m ago•0 comments

Nature's Hardware Store: building the future with biology [video]

https://aeon.co/videos/fungi-homes-and-more-ways-biology-could-sustain-life-beyond-earth
1•bryanrasmussen•4m ago•0 comments

Inside the next phase of OpenAI's political strategy

https://www.politico.com/news/2026/05/20/chatgpt-state-ai-fight-00928903
2•1vuio0pswjnm7•5m ago•0 comments

Trump Postpones AI Executive Order Due to Concerns About Overregulation

https://www.wsj.com/tech/ai/trump-executive-order-ai-advanced-models-57bcc955
2•berkeleyjunk•6m ago•0 comments

Japanese Verb Conjugation the Simple Hard Way

https://underreacted.leaflet.pub/3mmevu6woys27
1•danabramov•7m ago•0 comments

Show HN: Canonry tracks how AI cites you – agent-first, open source

https://github.com/AINYC/canonry
1•arberx•7m ago•0 comments

Show HN: Online Sound Test

https://soundtestx.com/
1•artiomyak•8m ago•0 comments

IRS requires identity verification with a private company for refunds?

https://help.id.me/hc/en-us/articles/8214940302999-IRS-and-ID-me
1•SilverElfin•9m ago•2 comments

Pivoting Out of Healthcare

https://saffron.health/
1•brandonb•10m ago•0 comments

AMD Ryzen AI Halo for AI Developers

https://www.amd.com/en/products/processors/desktops/ryzen/ryzen-ai-halo.html
1•9front•11m ago•0 comments

Show HN: My independent search engine focused on user control

https://slicksearchhq.com
1•nox21125•11m ago•0 comments

Adults who return to childhood games are searching for person they used to be

https://dailygalaxy.com/2026/05/psychology-childhood-games-nostalgia-adults-former-self/
1•amichail•11m ago•0 comments

Twitter Launches have become a scam and its visible

https://twitter.com/i/status/2057437455243153653
2•Fariz_Anjum•11m ago•0 comments

I had to do therapy on my AI

https://tinthe.dev/p/t/posts/therapy-for-ai
2•tinthedev•15m ago•0 comments

Rust for Linux Live

https://corrode.dev/podcast/s06e04-rust4linux/
1•K0nserv•15m ago•0 comments

Show HN: IDEViewer – Security scanner for malicious IDE Extensions

https://github.com/securient/ideviewer-oss
1•securient•15m ago•0 comments

Coding is solved? Software is not

https://arcplane.ai/journal/software-is-not-solved
2•arzak•15m ago•1 comments

US Government takes $2B equity stake in nine quantum computing firms

https://arstechnica.com/gadgets/2026/05/us-government-takes-2-billion-equity-stake-in-nine-quantu...
2•joozio•16m ago•1 comments

Tobacco Giant Donated $5M to MAGA Inc. Shortly Before Vaping Decision

https://www.wsj.com/business/tobacco-giant-donated-5-million-to-maga-inc-shortly-before-vaping-de...
1•petethomas•16m ago•1 comments

Amp Labs

https://ampcode.com/news/amp-labs
1•tosh•16m ago•0 comments

New Fragrance Tech Company

https://techcrunch.com/2026/05/21/a-new-fragrance-company-raises-2-million-to-find-new-scent-mole...
1•nate•17m ago•1 comments

More than 340 local news outlets are limiting the Internet Archive's access

https://www.niemanlab.org/2026/05/more-than-340-local-news-outlets-are-limiting-the-internet-arch...
2•jaredwiener•18m ago•0 comments

Ask HN: Anyone else struggling with AI and work?

3•carlgreene•18m ago•0 comments

Stop paying $360/year to access your own email history

https://mailvaulty.com
1•khaledsabae•18m ago•0 comments

UK radio station wrongly announces King Charles' death "due to computer error"

https://www.ctvnews.ca/world/article/radio-station-apologizes-after-accidentally-announcing-death...
2•theanonymousone•20m ago•0 comments