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

SK hynⅸ ru㎱ out of replacement SSDs and defaults to orig㏌al purc㏊se price refund

https://www.tomshardware.com/pc-components/ssds/sk-hynix-is-allegedly-out-of-replacement-ssds-for...
2•MiguelX413•3m ago•0 comments

PromoteOps MCP – Compare and promote AWS CloudFormation stacks across envs

https://www.npmjs.com/package/promoteops
1•HiteshShinde26•7m ago•0 comments

Bulgaria neutralizes GPS jammer that suppressed Sofia Airport signals

https://www.aerotime.aero/articles/bulgaria-sofia-gps-jammer-aircraft-navigation
2•r2sk5t•9m ago•0 comments

Let the Bond Market Speak

https://www.wsj.com/opinion/let-the-bond-market-speak-81529d74
1•gmays•10m ago•0 comments

Multiplatform Speech Recognition Runtime

https://github.com/k2-fsa/sherpa-onnx
1•measurablefunc•10m ago•0 comments

BMW Exec: Young People Prefer Voice and Screens over Buttons

https://www.thedrive.com/news/bmw-exec-says-young-people-prefer-voice-and-screens-over-buttons-be...
1•cf100clunk•11m ago•0 comments

How Universities Should Prepare Founders

https://paulgraham.com/prepare.html
6•gmays•12m ago•0 comments

Patreon Sends 1.1 MB of JSON to Show You 75 Chat Messages

https://www.joey.fyi/blog/patreon-ships-1mb-of-json
1•rpst•12m ago•0 comments

Was Modern Art a CIA Psy-Op?

https://daily.jstor.org/was-modern-art-really-a-cia-psy-op/
1•neom•17m ago•0 comments

Nvidia Vera Rubin NVL72 Rack at Hot Chips 2026

https://www.servethehome.com/nvidia-vera-rubin-nvl72-rack-at-hot-chips-2026/
1•pella•20m ago•0 comments

AMD Helios MI400 System Architecture at Hot Chips 2026

https://www.servethehome.com/amd-helios-mi400-system-architecture-at-hot-chips-2026/
1•pella•21m ago•0 comments

AMD MI400 GPU at Hot Chips 2026

https://www.servethehome.com/amd-mi400-gpu-at-hot-chips-2026/
1•pella•21m ago•0 comments

Protesting PS5 players now plan permanent blackout

https://www.pushsquare.com/news/2026/08/protesting-ps5-players-now-plan-permanent-blackout-meanin...
2•anigbrowl•24m ago•1 comments

Paying for Cached Tokens Sucks

https://twitter.com/lafalcemateo/status/2092061073750782139
1•lafalce•24m ago•0 comments

Enterprise AI Operating System

https://devnavigator.com/2026/08/25/enterprise-ai-operating-system/
1•devnavigator•27m ago•0 comments

Russian drone guided by AI kills civilians in Ukraine

https://www.aerotime.aero/articles/russian-drone-guided-entirely-by-ai-kills-civilians-in-ukraine
2•r2sk5t•34m ago•1 comments

I turned a crappy movie tracking spreadsheet for my friends into website

https://jesse.id/blog/my-friends-and-i-take-turns-picking-movies-to-watch-i-converted-our-crappy-...
2•jesse_dot_id•36m ago•0 comments

Some purchased movies on AppleTV are no longer accessible

https://twitter.com/AntoineRichard/status/2091845412151771449
3•erickhill•41m ago•0 comments

The Great Blood Pressure Scam – By a Midwestern Doctor

https://www.midwesterndoctor.com/p/the-great-blood-pressure-scam
1•bilsbie•43m ago•0 comments

Data Centre Slumlord

https://binary-mirror.itch.io/data-centre-slumlord
1•minimaxa•50m ago•0 comments

Nvidia says Groq racks will be online this year following $20B purchase

https://www.cnbc.com/2026/08/24/nvidia-says-groq-racks-will-be-online-this-year-after-20-billion-...
2•geoffbp•51m ago•0 comments

Runway Ruby

https://twitter.com/runwayml/status/2090807248402682101
1•handfuloflight•51m ago•0 comments

Flex: Let the Model Write the Code

https://www.cmpnd.ai/blog/let-the-model-write-the-code.html
1•gmays•52m ago•0 comments

Facial recognition mandatory in New South Wales gaming rooms under proposal

https://www.smh.com.au/politics/nsw/facial-recognition-mandatory-in-nsw-gaming-rooms-under-latest...
2•milderworkacc•57m ago•0 comments

I built an agent-skill that turns your texts into diagrams and BI-visuals

https://github.com/imshaikot/render-visual-skill
2•imshaikot•57m ago•0 comments

Spinifex: Production Cloud Deployments Where the Cloud Can't Reach

https://github.com/mulgadc/spinifex
3•toddyholiday•58m ago•0 comments

Migrating the SEO on page from custom codeto Laravel/head for Laraplugins

https://danielpetrica.com/laravel-head-package-migration/
2•danielpetrica•1h ago•0 comments

What languages are agent skills written in?

https://plicara.ai/research/agent-skill-languages/
6•3Mathematicians•1h ago•0 comments

Show HN: Pyrift – static analyser for silent Python/PyPy behaviour differences

https://github.com/BHUVANSH855/pyrift
2•BHUVANSH855•1h ago•0 comments

We Probably Can't Terraform Mars [video]

https://www.youtube.com/watch?v=mJF3JiwQk0g
2•binyu•1h ago•1 comments