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

"fn" is too cryptic.

"function" is better than the two.

MultifokalHirn•11mo ago
Agreed

Scaling Sameness

https://www.gradientinstitute.org/research-publications/scaling-sameness
1•dbaupp•27s ago•0 comments

Non-engineers don't know how to work with agents

https://mrprompty.com/features
1•ViktorPetrov•34s ago•1 comments

Brooks' Surgical Team Model and AI

https://jschof.dev/posts/2026/4/brooks-surgical-team-model-and-ai/
1•babybjornborg•44s ago•0 comments

Treetops glowing during storms captured on film for first time

https://www.psu.edu/news/earth-and-mineral-sciences/story/treetops-glowing-during-storms-captured...
1•t-3•46s ago•0 comments

Geometry Nodes in WebGPU

https://whoisryosuke.com/blog/2026/webgpu-node-graph/
1•juretriglav•2m ago•0 comments

Switching from Uv to PDM

https://stuartm.nz/2026/04/pdm-rocks/
1•birdculture•3m ago•0 comments

The Scraping Wiki: An LLM-maintained knowledge base indexing 400 articles

https://github.com/TheWebScrapingClub/scraping-wiki/blob/main/index.md
1•PigiVinci83•4m ago•0 comments

Crypto billionaire [Justin Sun] sues Trump-linked project alleging extortion

https://www.msn.com/en-us/money/companies/crypto-billionaire-sues-trump-linked-project-alleging-e...
1•bhouston•7m ago•1 comments

TeamPCP strikes again: Xinference (v2.6.0-2.6.2) PyPI package compromised

https://research.jfrog.com/post/xinference-compromise/
1•lukecarr•7m ago•1 comments

Books Are Not Remotely Too Expensive

https://www.millersbookreview.com/p/no-books-are-not-remotely-too-expensive
2•gHeadphone•7m ago•0 comments

Early data from Vera C. Rubin Observatory reveals over 11,000 new asteroids

https://phys.org/news/2026-04-early-vera-rubin-observatory-reveals.html
1•speckx•8m ago•0 comments

Can't wait to see this movie

https://www.youtube.com/watch?v=H-43VeYGiPM
1•alvineh•8m ago•0 comments

Python suite for neuroscience research across all modalities

https://github.com/facebookresearch/neuroai
1•MADEinPARIS•9m ago•0 comments

Qwen3.6-27B: Flagship-Level Coding in a 27B Dense Model

https://qwen.ai/blog?id=qwen3.6-27b
1•mfiguiere•9m ago•0 comments

The Single Dumbest Conspiracy Theory of 2026

https://www.theatlantic.com/science/2026/04/missing-scientists/686885/
2•Jtsummers•10m ago•0 comments

Larry McMurtry's Tall Tales

https://www.thenation.com/article/culture/larry-mcmurtry-biography/
1•samclemens•10m ago•0 comments

Google Cloud Fraud Defense, the Next Evolution of reCAPTCHA

https://cloud.google.com/blog/products/identity-security/introducing-google-cloud-fraud-defense-t...
1•throwaway29303•11m ago•0 comments

Qwen3.6-27B

https://twitter.com/i/status/2046939764428009914
1•NiekvdMaas•15m ago•0 comments

Show HN: ClickMVP – Deterministic full-stack code generation (no LLMs)

https://app.clickmvp.com/
1•andredourado•15m ago•0 comments

Congratulations Cursor on being acquired by SpaceX

https://blog.kilo.ai/p/congratulations-cursor-on-being-acquired
1•what_if_theory•15m ago•0 comments

Cheating at Tetris

https://chalkdustmagazine.com/features/cheating-at-tetris/
1•t-3•16m ago•0 comments

Google unleashes more AI security agents to fight the baddies

https://www.theregister.com/2026/04/22/google_unleashes_even_more_ai/
1•Brajeshwar•18m ago•0 comments

Schematik Is 'Cursor for Hardware.' Now, Anthropic Wants In

https://www.wired.com/story/schematik-is-cursor-for-hardware-anthropic-wants-in-on-it/
1•bookofjoe•18m ago•1 comments

Sam 2: Segment Anything in Images and Videos

https://chizkidd.github.io//2026/04/17/sam-2/
1•ibobev•19m ago•0 comments

Transformers

https://chizkidd.github.io//2026/04/17/transformers/
1•ibobev•20m ago•0 comments

Autoregression vs. Diffusion – Understanding Sampling via Optimal Transport

https://jiha-kim.github.io/posts/autoregression-vs-diffusion-understanding-sampling-via-optimal-t...
2•ibobev•20m ago•0 comments

Euphony: Visualize Chat Data in the Browser

https://openai.github.io/euphony/
1•gmays•22m ago•0 comments

Aphantasia and LLMs Or: Which Human Are We Talking About?

https://giorgio.gilest.ro/on-aphantasia-and-llms-or-which-human-are-we-talking-about/
1•crocowhile•23m ago•0 comments

Eridani-speak – make your LLM talk like Rocky from Project Hail Mary

https://github.com/SijuEC/eridani-speak
1•primax•23m ago•1 comments

When will quantum computing break cryptography?

https://blog.alcazarsec.com/tech/posts/when-will-quantum-computing-break-cryptography
1•alcazar•24m ago•0 comments