HN user

bslatkin

1,139 karma

https://onebigfluke.com

https://twitter.com/haxor

Posts72
Comments115
View on HN
www.youtube.com 3y ago

Mitchell Hashimoto uses a simple code editor

bslatkin
2pts0
www.onebigfluke.com 10y ago

How do you choose the programming language for a project?

bslatkin
2pts0
programmingisterrible.com 11y ago

San Francisco for Londoners

bslatkin
2pts0
www.onebigfluke.com 11y ago

You only get 1,000 lines of code a week

bslatkin
3pts0
www.onebigfluke.com 11y ago

The Data Triumvirate

bslatkin
2pts0
www.onebigfluke.com 11y ago

Python, C++, and Go as bicycles

bslatkin
4pts0
www.onebigfluke.com 11y ago

How I'm writing a programming book

bslatkin
2pts0
www.onebigfluke.com 12y ago

Go's power is in emergent behavior

bslatkin
222pts133
www.onebigfluke.com 12y ago

Maintaining open source projects is hard

bslatkin
2pts0
www.onebigfluke.com 12y ago

Feeling like a kid again – The joy of 3D printing

bslatkin
3pts0
neugierig.org 12y ago

React, JSX, and CoffeeScript

bslatkin
123pts69
www.onebigfluke.com 12y ago

Do OKRs work?

bslatkin
1pts0
www.onebigfluke.com 12y ago

Dyeing the cheese orange – Beware of benchmarks

bslatkin
35pts16
googlecloudplatform.blogspot.com 12y ago

An ode to Sharkon

bslatkin
3pts1
www.onebigfluke.com 12y ago

Programming is primarily a social endeavor

bslatkin
2pts0
plus.google.com 12y ago

Get Google Play Apps, Books, Music and More by Answering Surveys

bslatkin
3pts0
www.rfc-editor.org 12y ago

WebFinger: RFC7033

bslatkin
2pts0
www.onebigfluke.com 12y ago

"I will never use Python in production ever again"

bslatkin
14pts15
www.embracingchaos.com 12y ago

Making software architecture choices analytically with CodeTrend

bslatkin
1pts1
www.onebigfluke.com 12y ago

HTML only needs two verbs; throw away the REST

bslatkin
10pts2
groups.google.com 12y ago

Information on Google App Engine's recent US datacenter relocations

bslatkin
2pts0
medium.com 12y ago

The three axes of engineering leadership

bslatkin
1pts0
www.onebigfluke.com 12y ago

Let's remove verbs from HTTP 2.0

bslatkin
113pts136
techcrunch.com 12y ago

When The U.S. Government Knocked On Tim Draper’s Door About That $6 Million

bslatkin
1pts0
www.evilmadscientist.com 12y ago

Improving open source hardware: Visual diffs (2011)

bslatkin
2pts0
www.google.com 13y ago

"If she has a boy what do you think the baby's first name will be?"

bslatkin
3pts0
techcrunch.com 13y ago

Google Surveys Can Make Anyone A Professional Pollster

bslatkin
4pts0
www.onebigfluke.com 13y ago

Bootstrapping WebFinger decentralized discovery with WebFist

bslatkin
3pts0
www.onebigfluke.com 13y ago

Introducing Depicted: Safe continuous deployment

bslatkin
3pts0
www.youtube.com 13y ago

The Secret to Safe Continuous Deployment

bslatkin
1pts0

Scala has a lot of interesting concepts in it for sure! The problem is that the JVM is a deal-breaker, either because of its complexity or because of the associated licensing risk. Clojure has the same problem, for what it's worth.

For a very simple, single-expression lambda function I agree you don't need an explicit return. Even Python skips the "return" for lambdas. But for anything more complex, I find explicit returns, especially early returns, makes the code much more readable for people who are used to imperative languages.

For example, which of these is more clear to people who don't know Lisp? I'd argue the second one because of the early return if guard.

    ---- THIS ----

    (defun sum-helper (items total)
        (cond
            (items
                (sum-helper
                    (cdr items)
                    (+ total (car items))))
            (t total)))

    (defun sum (&rest items)
        (sum-helper items 0))

    (print (sum 1 2 3 4))

    ----- OR -----

    (defun sum-helper2 (items total)
        (if (not items)
            (return-from sum-helper2 total))

        (sum-helper2
            (cdr items)
            (+ total (car items))))

    (defun sum2 (&rest items)
        (sum-helper2 items 0))

    (print (sum2 5 6 7 8))

Let's keep going with the building analogy. You're running a cabinet making company. You've got all kinds of hand tools and power tools. You build jigs to make certain repetitive tasks faster. Then a ridiculously difficult design comes in for you to build. You and your crew are flummoxed by its complexity. Suddenly, someone offers you a CNC machine that you've never used before. What seemed hard is now easy. The nature of solving problems with a CNC is different. Using a CNC presents other challenges. But you have entered a new realm of what's possible. Analogies are a lot of BS but hopefully that gets across the flavor of what I'm talking about.

I love to swing a hammer as much as the next programmer. But if you offer me a nail gun, even with slightly lower precision, I will happily use it the majority of the time and revert to my hand tools when it's most appropriate. This is about developing force multipliers and producing leverage, not avoiding the craft.

I've got a working interpreter and compiler for the initial language. I've had a few people take it for a spin and they were able to rapidly learn it and start contributing, despite having expressed frustration in trying FP languages in the past. All anecdotes for now!

Thanks! Right now the language's codebase is about 50KLOC. There's an interpreter for fast iteration and a compiler built on LLVM for producing native binaries. I'd like to make more progress on the parallel computing functionality before sharing it more widely.

I agree that another language that's better for functional programming would make this more compelling. Python has a lot of limitations in this area. I think all of those alternatives you listed (Julia, Clojure, etc) include turn-offs for Python programmers that are deal breakers. So I'm seeking another language that appeals to Python programmers but has more of the attributes that are amenable to functional programming.

I wouldn't do the type checking in my head, I'd just assume it's going to work as intended. If that's not the case, then an error will happen. What's wrong with the user seeing an error? There's always a chance my program will have a bug and fail. So I have to handle that case no matter what and properly deal with unexpected errors, error reporting, etc.