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

"fn" is too cryptic.

"function" is better than the two.

MultifokalHirn•7mo ago
Agreed

The Number That Turned Sideways

https://zuriby.github.io/math.github.io/the-number-that-turned-sideways.html
1•tzury•2m ago•0 comments

Retroviral insertions contributed to the divergence of human and chimp brains

https://www.biorxiv.org/content/10.64898/2025.12.12.693858v1
1•XzetaU8•8m ago•0 comments

I Fed 24 Years of My Blog Posts to a Markov Model

https://susam.net/fed-24-years-of-posts-to-markov-model.html
2•susam•11m ago•0 comments

Rcarmo/Python-FastAPI-trmnl-server: Lightweight TRMNL BYOS server

https://github.com/rcarmo/python-fastapi-trmnl-server
2•rcarmo•13m ago•0 comments

MicroMint – invest small amounts together with friends

1•MicroMint•14m ago•0 comments

Climate Policy in Crisis: The Great Affordability Divide

https://rodgercuddington.substack.com/p/climate-policy-in-crisis-the-great
1•freespirt•14m ago•0 comments

Five Practical Robotics Applications Aimed at Reducing Environmental Impact

https://www.bbc.co.uk/bitesize/articles/zs7246f
1•soitgoes•15m ago•0 comments

Bookmark for CAD/2d/3D Useful links

https://github.com/yogananda-muthaiah/SAP-CPQ/tree/main/Integrations/CAD-2d-3d
4•yogananda•19m ago•1 comments

1000 Days in 32:9

https://blog.paavo.me/1000-days-in-32-by-9/
1•paavohtl•30m ago•0 comments

Transformer Architecture Visualizer

https://weavers.neocities.org/architecture-encyclopedia/
1•rain1•31m ago•1 comments

My new killer SaaS (Script-as-a-Service) – safe-claude.com

https://safe-claude.com
1•emilss•34m ago•3 comments

LLM Reflexion meta Core vs ML

1•alexandrkul•35m ago•0 comments

Megabonk

1•dimastopel•42m ago•0 comments

Energy Revolution System

https://sites.google.com/view/energy-revolution-systems/
1•healthcareuss•45m ago•0 comments

Software Freedom Conservancy vs. Vizio Inc

https://sfconservancy.org/copyleft-compliance/vizio.html
2•pabs3•49m ago•0 comments

Waterfox 6.6.6 release notes: Privacy hardening

https://www.waterfox.com/releases/6.6.6/
3•thomassmith65•50m ago•1 comments

Photo of skydiver 'falling' past the sun's surface

https://www.livescience.com/space/the-sun/astrophotographer-snaps-absolutely-preposterous-photo-o...
1•Anon84•51m ago•0 comments

Humans rank above meerkats but below beavers in monogamy league table

https://www.theguardian.com/science/2025/dec/10/humans-rank-among-leading-monogamous-mammals-stud...
3•wjSgoWPm5bWAhXB•56m ago•0 comments

The Code That Revolutionized Orbital Simulation [video]

https://www.youtube.com/watch?v=nCg3aXn5F3M
1•RossBencina•1h ago•1 comments

The real lock-in in GitHub is not the code, but the stars

https://ashishb.net/tech/github-stars/
5•ashishb•1h ago•3 comments

'Food and fossil fuel production causing $5B of environmental damage an hour'

https://www.theguardian.com/environment/2025/dec/09/food-fossil-fuel-production-5bn-environmental...
2•robtherobber•1h ago•0 comments

Attitudes towards AI by country (2025)

https://old.reddit.com/r/dataisbeautiful/comments/1pl7xbe/oc_attitudes_towards_ai_by_country_2025/
1•embedding-shape•1h ago•1 comments

Pixel advertising wall for influencers with real-time reservation

https://influencerswall.com/
2•YurGrhm•1h ago•1 comments

Rich Headers: leveraging this mysterious artifact of the PE format

https://www.virusbulletin.com/virusbulletin/2020/01/vb2019-paper-rich-headers-leveraging-mysterio...
2•todsacerdoti•1h ago•0 comments

Building a Multiplayer Game with Polyglot Microservices: Architecture Lessons

https://gitlab.com/RobinTrassard/codenames-microservices/-/tree/account-java-version
1•birdculture•1h ago•0 comments

I was tired of removing video backgrounds, so I built a simpler solution

https://removebgvideo.com/
1•quchao•1h ago•2 comments

Unpredictable code behavior is a hidden driver of cloud waste

https://portugalstartupnews.com/2025/12/12/the-cloud-mistake-that-quietly-drains-startup-runway/
1•rodriguejr•1h ago•1 comments

Building Trustworthy AI Agents

https://www.schneier.com/blog/archives/2025/12/building-trustworthy-ai-agents.html
1•Garbage•1h ago•0 comments

'It May Be Worse'–No Fix for New Google Chrome Attacks

https://www.forbes.com/sites/zakdoffman/2025/12/12/it-may-be-worse-no-fix-for-new-threat-to-googl...
4•ColinWright•1h ago•0 comments

A net of scammer groups on Telegram

https://timsh.org/scam-telegram-investigation/
2•timsh•1h ago•0 comments