Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
cyphar
on March 13, 2016
|
parent
|
context
|
favorite
| on:
Ask HN: What are some examples of beautiful softwa...
The recursive Fibonacci definition in Haskell is far more beautiful IMO. But there's always more beautiful one-line snippets (like the regex that can tell you if a number is prime).
fibs = 0 : 1 : zipWith (+) fibs (tail fibs)
Consider applying for YC's Winter 2027 batch!
Applications
are open till November 2.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search:
fibs = 0 : 1 : zipWith (+) fibs (tail fibs)