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

Chess Openings by Nationality

https://jamesshapiro.com/writing/chess-openings-by-nationality
1•stephsmithio•2m ago•0 comments

Show HN: Musql, JIT-compiled SQL, up to 300x faster than SQLite, 1000x vs. Turso

https://github.com/samyfodil/musql
1•dsamy•3m ago•0 comments

The Alchemical Transformations of the Mutus Liber (1677)

https://publicdomainreview.org/collection/mutus-liber/
1•benbreen•3m ago•0 comments

We Asked Starbucks Why Their 'Sugar-Free' Drinks Have Sugar

https://gizmodo.com/we-asked-starbucks-why-their-sugar-free-drinks-have-sugar-and-now-were-just-m...
2•Tomte•7m ago•0 comments

GoatedContext: Cross-repo, local preference context and cross-agent injection

https://github.com/razzyshmazzy/goatedcontext
1•nicozametto•8m ago•0 comments

How to keep learning in the age of LLMs

https://ogzhanolguncu.com/blog/how-to-keep-learning-in-the-age-of-llms/
1•shraddhaag•11m ago•0 comments

Experimental MSU-1 streaming and standard-memory profiles

https://github.com/agg23/openfpga-SNES/pull/123
1•Tomte•13m ago•0 comments

Sharded, encrypted storage between friends over Yggdrasil

https://github.com/peterretief/yggstore
1•peter_retief•13m ago•0 comments

Designing for Voice-First

https://www.antonsten.com/articles/designing-for-voice-first/
1•cat-whisperer•15m ago•0 comments

Show HN: Rgpu – a PyTorch device whose tensors live on a remote GPU

https://github.com/ymcrcat/rgpu
1•boxstream•18m ago•0 comments

Show HN: Pareto Partisan? Relative Gains and Support for Public Policy

https://github.com/soodoku/pareto_partisan
1•neehao•22m ago•0 comments

Show HN: Detangle, Dependency rules for JavaScript, checked in under a second

https://www.debugdiary.dev/log/detangle-dependency-rules-for-javascript-in-under-a-second
1•debug-diary•22m ago•0 comments

Thoughts on This Website Audit?

https://www.crawkcheck.io/
1•emmanss•25m ago•0 comments

Is Criminal Forensics Bullshit?

https://nautil.us/is-criminal-forensics-bullshit-1285587
2•Tomte•29m ago•0 comments

Botanical Contact Printing

https://www.jennydean.co.uk/contact-printing-on-fabric-and-paper/
1•t-3•30m ago•0 comments

I mortgage my house so you can vibe code while pooping

https://www.jackhamr.ai
1•jrda•30m ago•0 comments

Mistral Large 4 Preview: Intelligence, Performance and Price Analysis

https://artificialanalysis.ai/models/mistral-large-4
2•theanonymousone•34m ago•0 comments

Toketer – See what every AI prompt costs you, live in your editor

https://marketplace.visualstudio.com/items?itemName=toketer.toketer
1•soumyadeep-toke•37m ago•0 comments

Show HN: KORA Doctor – find LLM calls your agent may not have needed

https://github.com/Krako-Labs/kora-doctor
1•hkalbert71•38m ago•0 comments

Show HN: Snug, a local-only bookmark export, import and backup extension

https://github.com/AndryOre/snug
1•AndryOre•39m ago•0 comments

Gigabyte B300 Workstation PC

https://www.gigabyte.com/press/news/2317
1•willvk•40m ago•1 comments

Crunchbase Data Shows AI's Most Active Startups Are Becoming Serial Acquirers

https://news.crunchbase.com/ma/ai-startup-acquisitions-legal-healthcare-openai/
1•snikolaev•43m ago•0 comments

AI-powered time tracking for freelancers and agencies

https://www.tracktimer.app
1•welsenesbros•43m ago•0 comments

Vote to Promote Sergey Miryanov

https://discuss.python.org/t/vote-to-promote-sergey-miryanov/109283
1•GloVin•45m ago•0 comments

I'm Broke and Mostly Friendless, and I've Wasted My Whole Life (2018)

https://www.thecut.com/2018/11/im-broke-and-friendless-and-ive-wasted-my-whole-life.html
1•soulofmischief•46m ago•0 comments

The S&P 500 Hits a New Record High, Powered by Tech–and Not Much Else

https://www.wsj.com/finance/stocks/the-s-p-500-hits-a-new-record-high-powered-by-techand-not-much...
1•doener•47m ago•0 comments

The reason Anthropic must IPO now [video]

https://www.youtube.com/shorts/E80oYhrGa8c
1•thelastgallon•50m ago•0 comments

AlphaSteel Review 2026: Ingredients, Benefits and Complete Guide

https://script.google.com/macros/s/AKfycbwV2N-YUcgAYobr4uCu8TKqL0Gm8C5bVHWXp0fqHdwGE-WZuXoH1idAjw...
1•ralugatz•53m ago•0 comments

Chrome's Response to Recent CcTLD Registry Hijacks

https://blog.google/security/chromes-response-to-recent-cctld-registry-hijacks/
2•shscs911•53m ago•0 comments

The Origin of Consciousness in the Breakdown of the Bicameral Mind

https://en.wikipedia.org/wiki/The_Origin_of_Consciousness_in_the_Breakdown_of_the_Bicameral_Mind
1•aggrrrh•55m ago•0 comments