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

Why College Grads Are Booing Their Commencement Speakers

https://www.nytimes.com/2026/05/18/opinion/ai-boo-commencement-speeches.html
1•65•47s ago•0 comments

Android CLI Now Stable 1.0

https://android-developers.googleblog.com/2026/05/android-cli-stable-1-0-agent-development.html
1•vyrotek•1m ago•0 comments

Yet Another AI Teammate

https://yaat.sh/
1•e7h4nz•4m ago•0 comments

Intelligent eyewear is coming this fall

https://blog.google/products-and-platforms/platforms/android/android-xr-io-2026/
2•decimalenough•9m ago•0 comments

Build managed agents with the Gemini API

https://blog.google/innovation-and-ai/technology/developers-tools/managed-agents-gemini-api/
1•ddl•9m ago•1 comments

Lighthouse Attention

https://nousresearch.com/lighthouse-attention
1•gmays•10m ago•0 comments

Anthropic Announces Managed Agents – what this means for consumers

https://www.greatworkeveryone.com/writing/cheap-cloud-ai-was-never-going-to-last
1•connorrandazzo•14m ago•0 comments

Why raw blockchain logs are no longer enough

https://blog.bridgexapi.io/bxruntime-terminal-the-rise-of-execution-observability-for-evm-systems
1•Bridgexapi•18m ago•0 comments

State of Crypto 2025: The year crypto went mainstream

https://a16zcrypto.com/posts/article/state-of-crypto-report-2025/
2•Anon84•20m ago•0 comments

Trump Mobile has a real phone, but it may also have a real data leak

https://www.androidauthority.com/trump-mobile-customer-data-link-3668917/
1•bilekas•22m ago•0 comments

Trusted Publishing for NPM Packages

https://docs.npmjs.com/trusted-publishers/
1•healsdata•23m ago•0 comments

Show HN: Reckoner – a semantic browser for structured data

https://reckoner-production.up.railway.app/
1•abk9811•23m ago•1 comments

Ask HN: Natural Language App Testing?

6•devstein•26m ago•0 comments

Google's SynthID AI watermarking tech is being adopted by OpenAI, Nvidia

https://arstechnica.com/google/2026/05/googles-synthid-ai-watermarking-tech-is-being-adopted-by-o...
3•jonbaer•26m ago•0 comments

Agentic PCB Design Sucks

https://github.com/hpm-registry/registry
2•JoonSPP•28m ago•1 comments

Remove AI Watermarks

https://github.com/wiltodelta/remove-ai-watermarks
23•janalsncm•31m ago•9 comments

Show HN: Remindy – A Spotlight-style reminder app for Mac

1•fayecat910•31m ago•0 comments

Language Models Can Autonomously Hack and Self-Replicate

https://palisaderesearch.org/blog/self-replication
2•cassianoleal•33m ago•0 comments

Censorship Request from Coin Insider (2024)

https://support.bitchute.com/blog/bitchute-receives-censorship-request-from-coin-insider
2•aand16•33m ago•0 comments

RemotePower – Self-hosted Linux fleet manager (no database, pure Python)

https://github.com/tyxak/remotepower
1•tyxak•34m ago•1 comments

Show HN: Trophy UI, Open-source gamification components built on Shadcn

https://ui.trophy.so
1•cbrinicombe•36m ago•0 comments

Show HN: AgentWing – make AI agents complete tasks faster

1•12ziyad•36m ago•0 comments

Google Antigravity Python SDK

https://github.com/google-antigravity/antigravity-sdk-python
1•devhouse•37m ago•0 comments

Detecting Relaxed Memory Concurrency Bugs in C and C++ Compilers

https://lukegeeson.com/publications/2026-04-28-Thesis/
3•matt_d•44m ago•0 comments

IRS Must Drop Audits of Trump and Family

https://www.nytimes.com/2026/05/19/us/politics/trump-irs-doj-lawsuit-audit.html
13•duxup•45m ago•2 comments

The downgrading semantics of memory safety (Extended version)

https://arxiv.org/abs/2507.11282
2•matt_d•48m ago•0 comments

Self-Improving Reward Models

https://www.canvas.inc/research/reward-models
2•essamsleiman•50m ago•0 comments

AI and the Practical Scientist

https://scholarlyfutures.substack.com/p/ai-and-the-practical-scientist
1•JohnHammersley•51m ago•0 comments

React Performance Isn't About UseMemo – It's About Render Boundaries

https://reactdevelopment.substack.com/p/react-performance-isnt-about-usememo
1•javatuts•53m ago•1 comments

AgentPTY: Script Claude Code’s interactive CLI through a persistent PTY

https://github.com/quietforgelabs/AgentPTY
2•quietforgelabs•55m ago•1 comments