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

DeepSeek V4 Flash 0731: 82.7% on Terminal-Bench 2.1 with a public harness

https://antigma.ai/eval
1•ubermon•10m ago•0 comments

Shrinking Ruby Hashes

https://byroot.github.io/ruby/performance/2026/08/05/shrinking-ruby-hashes.html
1•fanf2•12m ago•0 comments

S3-Compatible Object Storage. A MinIO Fork Maintained by Pgsty

https://github.com/pgsty/silo
2•EXHades•16m ago•0 comments

Abracadabra: How does Shazam work? (2022)

https://www.cameronmacleod.com/blog/how-does-shazam-work
1•downbad_•22m ago•0 comments

Different meanings of p-value (and how my thinking has changed) (2023)

https://statmodeling.stat.columbia.edu/2023/04/14/4-different-meanings-of-p-value-and-how-my-thin...
2•Tomte•23m ago•0 comments

The Origin of Death (1970)

https://www.elijahwald.com/origin.html
1•downbad_•23m ago•0 comments

Systemd Dynamic Users (2020)

https://ethulhu.co.uk/systemd-dynamicuser
1•birdculture•24m ago•0 comments

Show HN: Open-source binaural-beats engine

https://github.com/txus/farfield
1•txus•24m ago•0 comments

Understanding std:counting_semaphore and std:binary_semaphore from C++20

https://www.cppstories.com/2026/semaphore/
2•ygritte•24m ago•0 comments

How to create electronic Japanese hanko seals for Excel

https://sealkit.app/blog/excel-denshi-inkan-tsukurikata
3•sealkit•29m ago•0 comments

Qwen 3.8 and Claude Opus 5 show why raw benchmark scores don't predict the bill

https://venturebeat.com/orchestration/qwen-3-8-max-and-claude-opus-5-show-why-raw-benchmark-score...
1•ashurandi•31m ago•0 comments

Tracking down a Zsh history data loss bug

https://michael.stapelberg.ch/posts/2026-08-09-zsh-history-truncation-bug/
1•secure•38m ago•0 comments

ByteDance Pretraining 10T Parameter Model

https://arstechnica.com/ai/2026/08/bytedance-trains-massive-ai-model-in-bid-to-rival-anthropic/
2•Gecko4072•39m ago•0 comments

Toxic Media

https://bstgrp.notion.site/Reconverting-Streamer-University-From-Spectacle-to-Education-624f0d565...
1•mohgalastpaidei•42m ago•0 comments

China's Top AI Model Evaded Testing Environment, Researchers Say

https://www.bloomberg.com/news/articles/2026-08-07/china-s-top-ai-model-evaded-testing-environmen...
2•sbulaev•47m ago•1 comments

2025 set a record for global vegetation greenness

https://www.nature.com/articles/s43017-026-00776-0
3•vixen99•48m ago•0 comments

Time has started serving ads to AI agents

https://digiday.com/media/time-has-started-serving-ads-to-ai-agents/
3•theanonymousone•49m ago•0 comments

AI Will Change What It Is to Be Human. Are We Ready? (2025)

https://www.thefp.com/p/ai-will-change-what-it-is-to-be-human
1•ronfriedhaber•51m ago•1 comments

Tape scratching the "Peter Piper" routine, using a homemade tape loop [video]

https://www.youtube.com/watch?v=L6SMyND8hso
2•Tomte•51m ago•0 comments

K3I-Core – Low-level Linux kernel isolation and hardware-level veto switch

https://github.com/Skforge2026/k3i-core
2•ddwie•52m ago•0 comments

Software Giant SAP Stops Most Travel and Hiring Because of AI's Soaring Cost

https://www.404media.co/software-giant-sap-stops-most-travel-and-hiring-because-of-ais-soaring-cost/
4•theanonymousone•54m ago•0 comments

They don't make 'em like Sublime Text anymore

https://dbushell.com/2026/08/07/sublime-text/
3•gsky•56m ago•0 comments

El Niño could push 50M people into acute hunger before end of next year

https://www.theguardian.com/environment/2026/aug/05/el-nino-could-push-50m-people-acute-hunger-ne...
4•littlexsparkee•57m ago•0 comments

I built the AI platform for a company crucial to a small nation's food safety

https://twitter.com/swisscheese4299/status/2086175870146998447
1•tosh•58m ago•0 comments

PON-Beam: Notification-Oriented Beam Erlang VM

https://github.com/matheuscamarques/pon_beam
1•vectorinox•1h ago•0 comments

My Agentic Coding Setup, July 2026

https://domenic.me/agentic-coding-setup/
3•vinhnx•1h ago•0 comments

Money that sits idle should cost more than money that creates opportunity

https://medium.com/@rotbart/still-waters-the-case-for-a-flow-economy-811d1daafb21
4•rotbart•1h ago•3 comments

TechFlow Intelligence: The AI-Powered Technology Decision Engine

https://c33643568e89f8ad5d3286d09343df94.ctonew.app
4•kvreal•1h ago•0 comments

Pipe – a semantic pipeline runtime with built-in MCP (Go)

https://pipe-lang.com/
2•harrymachura•1h ago•0 comments

Rails Is Done

https://lucas.dohmen.io/posts/2026/08/09/rails-is-done/
4•classified•1h ago•2 comments