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•6mo 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•6mo 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•6mo 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•6mo 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•6mo ago
"def" is too generic.

"fn" is too cryptic.

"function" is better than the two.

MultifokalHirn•6mo ago
Agreed

Stem cell therapy helps AMD patients see again

https://www.sciencedaily.com/releases/2025/11/251121090736.htm
1•GeorgeWoff25•2m ago•0 comments

It's Not Always DNS: Exploring How Name Resolution Works

https://cefboud.com/posts/dns-name-resolution-deep-dive-internals/
2•byt3h3ad•3m ago•0 comments

Subtle Signs That You Are Ready to Retire

https://www.wsj.com/lifestyle/careers/retirement-ready-when-signs-d0c99bd3
1•Anon84•8m ago•1 comments

Bagaimana Cara Menghubungi CS Batik Air

1•R33VIL•9m ago•0 comments

WordPress Deep Dive

https://wiktorjarosz.com/wordpress/introduction/
1•thunderbong•10m ago•0 comments

CS Batik Air? +62.811.323.170

1•R33VIL•12m ago•0 comments

Liballocs: Meta-level run-time services for Unix processes a.k.a. dragging U

https://github.com/stephenrkell/liballocs
1•todsacerdoti•14m ago•0 comments

Bossware rises as employers keep closer tabs on remote staff

https://www.theregister.com/2025/11/23/bossware_monitor_remote_employees/
1•beardyw•14m ago•0 comments

Show HN: Zig's defer/errdefer for c99 and gnu11 C

https://github.com/Trainraider/defer_h
1•Major_Baby_425•16m ago•0 comments

What Is a Shader?

https://www.makingsoftware.com/chapters/shaders#email
1•vismit2000•21m ago•0 comments

Show HN: Building a no-code browser automation system for OSINT

https://github.com/FauvidoTechnologies/PyBrowserAutomation
1•purge12•22m ago•0 comments

Nano Banana Pro (4K) at $0.04/image

https://seedreamimage.com/nano-banana-pro
1•xbaicai•22m ago•1 comments

Apple iOS 27 to Be No-Frills 'Snow Leopard' Update, Other Than New AI

https://www.bloomberg.com/news/newsletters/2025-11-23/apple-ios-27-snow-leopard-like-quality-focu...
2•sebiw•24m ago•1 comments

Amazon cut more than 1,800 engineers in record layoffs

https://www.cnbc.com/2025/11/21/amazon-cut-thousands-of-engineers-in-its-record-layoffs-filings-s...
2•miked85•24m ago•0 comments

Demand for UK Food Bank Up 15% Year on Year

https://www.theguardian.com/society/2025/nov/23/food-banks-demand-prices-frontline-cost-of-living...
19•rcarr•29m ago•8 comments

Doge 'doesn't exist' with eight months left on its charter

https://www.reuters.com/world/us/doge-doesnt-exist-with-eight-months-left-its-charter-2025-11-23/
2•geox•38m ago•1 comments

Tosijs-schema is a super lightweight schema-first LLM-native JSON schema library

https://www.npmjs.com/package/tosijs-schema
9•podperson•38m ago•3 comments

Show HN: Promptsref – Curated Midjourney SREF library with full prompts

https://promptsref.com/
1•underwoodxie•40m ago•0 comments

Show HN: I built a simple, fast, privacy-first document scanner for iPhone

https://apps.apple.com/us/app/scan-convert-to-pdf-images/id6727013863
1•JulienLacr0ix•41m ago•0 comments

OpenAI is launching group chats in ChatGPT

https://www.theverge.com/news/825544/openai-chatgpt-group-chats-launch
1•MindBreaker2605•44m ago•0 comments

Racket v9.0

https://blog.racket-lang.org/2025/11/racket-v9-0.html
2•Fice•46m ago•0 comments

The Arrival of Self Driving

https://avc.xyz/the-arrival-of-self-driving
1•wslh•46m ago•0 comments

Microsoft Will Preload Windows 11 File Explorer to Fix Bad Performance

https://www.techpowerup.com/343149/microsoft-will-preload-windows-11-file-explorer-to-fix-bad-per...
3•ksec•47m ago•0 comments

Security BSidesLjubljana 0x7EA – CFP Open

https://0x7ea.bsidesljubljana.si/
1•lowk3y•48m ago•1 comments

How Proper Names Behave in Text Embedding Space

https://vectors.run/posts/your-embeddings-know-more-about-names-than-you-think/
2•etoud•49m ago•1 comments

The Geometric Origin of Inertia and Dynamics [pdf]

https://zenodo.org/records/17672563
2•MKEPhysics•50m ago•1 comments

Is AI Valuation Bubble About to Burst ?

https://medium.com/@anwarzaid76/ai-valuation-bubble-will-burst-and-nobody-is-ready-01d622cfc1bb
3•MindBreaker2605•53m ago•0 comments

AI Agents for Enterprise – A Practical Guide for C-Level Leaders

https://lightrains.com/blogs/ai-agents-enterprise-practical-guide-c-level-leaders/
1•niksmac•54m ago•0 comments

Recursive merge sort as a recursive sequence diagram

https://app.ilograph.com/demo.ilograph.Merge%2520Sort/Merge%2520Sort%2520Main
1•billyp-rva•56m ago•0 comments

Claude Code Is Down

https://status.claude.com/incidents/538r2y9cjmhk
13•throwpoaster•57m ago•4 comments