HNHacker News
TopNewBestAskShowJobs

ericssmith

283 karma · joined December 10, 2011

https://www.functionalgeekery.com/episode-37-eric-smith/
submissionscomments
ericssmith··on Ask HN: I'm a young developer. What should I do next?
Holy smokes. You're 14. Forget about "web design" and having a business. This isn't 2005. Don't set the bar for yourself so low. Aim high. You are the next generation in the greatest technological advance in the history of human kind. Do something hard. Find a language with a type system. Implement something meaningful in it. Russell and Norvig's "Artifical Intelligence" is full of great, inspirational stuff.
ericssmith··on NSA Phone Snooping Cannot Be Challenged in Court, Feds Say
This is akin to the argument Thomas Paine made in "Common Sense" http://bit.ly/168gJkB that fired up the colonists in early 1776. "We consent ourselves to be governed" and if we select one or more among us to carry out our business, those folks don't have rights that the rest of us don't.

However, even at the time, there were "elites" among the colonists who wouldn't have agreed. And so its been ever since. The rhetoric of a democratic republic used to sway and motivate regular folks in order to protect the power and interests of a few.

ericssmith··on Mission Creep: When Everything Is Terrorism
I think it's worth distinguishing between the iron-fisted totalitarianism of the 20th century, colonialism of the 19th century, and military based hegemony going into the 21st. The iron-fisted path to empire didn't work out too well. But I think "total" control is the goal in all cases.
ericssmith··on The Case for Abolishing the DHS
I was also creeped out (still am) by the name, especially given the spirit of the times (eg yellow ribbons etc). I had the same sense as described here: http://www.alternet.org/speakeasy/alyssa-figueroa/dissecting...

I was also surprised at the time by often seeing "Department of Defense", as we were bunker busting and daisy cutting the crap out of people across the globe. I also just recently learned that we don't know the number of US military installations around the globe (700?, 900?) and instead of dismantling them after collapse of USSR, we found new justifications.

ericssmith··on Using weather as a trading signal
"transaction costs made trading based off of this strategy almost not worth it"

Be interesting to know how it stacks up against other approaches in this regard.

"main point here is that it's interesting"

That it is.

ericssmith··on Using weather as a trading signal
This comment caught my eye: "because after transaction costs it did not show enough of a gain"

I've always wondered why assumptions about transaction costs and execution speed never show up in these kinds of "studies". Anyone who has participated in markets understands they have a significant impact on results.

Also, doesn't it seem obvious that you would analyze the results based on multiple random entry & exit points rather than cherry-picked (or arbitrary) time periods?

ericssmith··on Why the world needs Haskell
FWIW, the constructs with the initial biggest win for us (in converting procedural thinking) were pattern matching and option types. For pattern matching, the guidelines were

- Don't do any processing after the pattern match within a function; break into smaller functions

- Reach for pattern matching before if/else

- Avoid the use of var

- Avoid dropping through to wildcard pattern. (This tip was from Yaron Minsky of OCaml fame)

In conjunction with preferring the use of combinators over loops, and using Option (and being forced to think about None), we got surprisingly functional Scala code in a short time.

ericssmith··on Why the world needs Haskell
I assume by "non-native", you mean "non-idiomatic"?

Since I recently went through coworkers writing "bad" (by which I mean non-idiomatic) Scala, and repairing the situation, I can say that it was surprisingly easy to lay down "functional constructs" and the result was amazing. The code became reliable, well-structured, and easy to leverage. Switching to Scala for our projects -- including introducing procedurally minded programmers to it -- was a huge win for us.

ericssmith··on Math, Science Popular Until Students Realize They’re Hard
"My argument is that sorting is not what schools were invented for"

Hmmm, are you sure about that?

Being a student and learning are not the same thing. To be successful in school, you have to excel at the former.

ericssmith··on Ask HN: Educating a child who is severely behind
Sorry to sound cynical, but toddlers and pre-schoolers are easily the most confounding, frustrating creatures on the planet. They are experts at exposing your dark corners and jangling your nerves. You will not be feeling or thinking 'love' at that point. If you are looking for single word remedies, then 'tolerance', or 'patience' are closer to the mark.
ericssmith··on Ask HN: Educating a child who is severely behind
Relax about the potty training. Frequent reminders, sticker chart, and bigger milestone rewards are all you need. Kids are on their on timeline with this, and any anxiety you have around it won't help. Regarding speech, repeat back clearly what the boy says to you. A speech therapist helps. It is a long, gradual process. Facilitated play (i.e., guided by adult) with peers is huge.
ericssmith··on How Google plans to rule the computing world through Chrome
This observation brings some potential context to the rationale for the Dart language.
ericssmith··on How to Learn Emacs: A Hand-drawn One-pager for Beginners
Something like this ...

(require 'color-theme) (color-theme-initialize) (load-file "~/.emacs.d/themes/color-theme-sunburst.el")

ericssmith··on Dart Is Not the Language You Think It Is
This video (at 26:13) gives a pretty good example of why these might be useful: "Dart: Google's evil plan to make it easier for you to build web apps" http://www.youtube.com/watch?v=9RCuW6K1afs
ericssmith··on How to Learn Emacs: A Hand-drawn One-pager for Beginners
You might like color-theme-sunburst.el based on your screenshot.
ericssmith··on Why SICP Matters
"there's ten different ways to do everything"

I believe this observation is a bit misleading. Indeed, Scala does offer some alternatives, but these are helpful in the transition from other languages with less powerful type systems. Idiomatic Scala is not really a hodge-podge of choices.

ericssmith··on How I coded in 1985
I had a KIM-1 in the late seventies and for several years I would run into other people who used one, but 1985 seems really late for programming on one of these. For me, the KIM-1 was my first experience with programming and a computer of any sort. It influenced my taste for low-level concepts, not only through x86 assembly programming for graphics in the 90s but much later in the lambda calculus and combinatory logic. I'm tickled that the KIM-1 is seeing such a resurgence of interest.
ericssmith··on What I Wish I Knew When Learning Haskell
Hudak's 'Haskell School of Expression' is also full of much Haskell wisdom and spirit.
ericssmith··on What I Wish I Knew When Learning Haskell
The 'best' introductory book for learning Haskell is Graham Hutton's 'Programming in Haskell'. It focuses on the essentials of the language, and its clear, spare presentation is in the spirit of Haskell itself. And it is accessible to everyone.
ericssmith··on Booth Babes, Street Clothes, and GDC: Thanks But You sort of Made It Worse
I am not sick of gender issues. I have recently been enlightened (mostly by Bob Martin's recent blog post) about language that I use at work (eg military analogies) that could be alienating to anyone (eg females) who didn't grow up idealizing warfare. This is an incredibly important point in history, and you are at the epicenter. Thanks for sharing your experience.
ericssmith··on Vim speed is not really the point
I work between Emacs and IntelliJ pretty seemlessly. Bread and butter editing is done in IntelliJ, which has Emacs keybindings that I've tweaked to match my Emacs customizations (generally after the recommendations of Steve Yegge). But then I can drop into Emacs for the same file and line when I need to do more heavy duty transformations. Here's the IntelliJ setup:

File > Preferences > External Tools

Program: /Applications/Emacs.app/Contents/MacOS/Emacs

Parameters: +$LineNumber$ "$FilePath$"

Working Directory: /Applications/Emacs.app/Contents/MacOS

Then I map a key to open this (Cmd-E)

On the emacs side, I have the following to pick up changes to an open buffer that were made in Intellij

(global-auto-revert-mode 1)

ericssmith··on Clojure: All grown up
I think you are correct here. In my view, advanced languages facilitate the development of complex abstractions in the libraries. I find this to be the case in both Haskell and Scala. But I also don't think we will ever return to the innocent days of yore. Programming is growing up after six decades of trying to figure out what 'mainstream' ought to be. I suspect that the whole business will bifurcate into easy-to-use languages and increasingly complex libraries atop more sophisticated languages to meet the challenges of scale and speed.
ericssmith··on IntelliJ IDEA 12 Wins Jolt Award for Coding Tools 2013
This is just about my mix for Scala. I have keybindings in Intellij fairly close to what I use in Emacs, and both will update when files are edited. I drop into Emacs when I have heavy editing, need to bounce around multiple buffers, or trying things out in the REPL.

I also work in a number of non-JVM languages in Emacs, and have used it for quite a long time. For JVM work, IntelliJ is, as you say, 'a little more productive'.

ericssmith··on Hello Haskell, Goodbye Scala
Our company uses both Scala and Haskell for revenue-producing projects. There's a lot that goes into choosing a language for such projects. I think it's fair to say that Scala is not really a beginner friendly language, nor do I think it is meant to be. Odersky's Coursera course is pretty heavily inspired by SICP (see 'Scala by Example' for an earlier manifestation of this material). And SICP was definitely designed to be used as an intro to programming. But as anyone who has gone through SICP can attest, it's probably not the best choice for a lot of people. But the Coursera Scala course is good in much the same way that SICP is. It is deep and well designed. Just not for everyone.

Haskell has relatively simple syntax and coherent semantics (being unencumbered by a 'foreign' VM eco-system, such as the JVM). As such, it is somewhat easier to get into. But to quote Gerry Sussman (co-author of SICP and Scheme), 'Haskell is the most advanced of the obsolete languages'. It gets deep pretty fast. You don't learn Haskell, so much as get initiated into it. It's an ongoing process. This can be said of Scala as well. Neither are particularly small languages when you consider their entire respective eco-systems.

In general, if you are already competent in a mainstream, dynamic language, and want to get your feet wet in functional language concepts, diving into Haskell is not a bad idea; but you are not likely to stick with it. I would recommend Clojure for such people. However, if you are already a Java programmer (and don't completely hate it), then the transition to Scala will be tough, but somewhat gradual. It is designed to be. But I would also say that the Scala world (not so much the language itself) is easier to grok if you know Haskell to at least an intermediate level. I think it is worth the time to learn Haskell and build something useful with it. It does not need to precede learning Scala, however.

ericssmith··on Why learning Haskell makes you a better programmer
"ridiculously fun and easy-to-read style"

But if you find 'fun' and large amounts of text distracting, then Graham Hutton's 'Programming in Haskell'[1] is a better introduction to what Haskell is about.

[1] http://www.cs.nott.ac.uk/~gmh/book.html

ericssmith··on What Compsci textbooks don't tell you: Real world code sucks
A more revealing and accurate look at software in the real world is 'Big Ball of Mud': http://www.laputan.org/mud/

As a Haskell programmer, I thought the Taliban comment was funny.

ericssmith··on What's new in Servlet 3.1? - Java EE 7 moving forward
"You may not find it as such, but the language's kitchen-sink approach to features does have its drawbacks; I find that part of it manageable but that doesn't mean it's not complicated, it means I can deal with it."

I don't find the language to be a kitchen-sink at all. It is a fusion of OO and FP, and so would reasonably be expected to support features from each of those paradigms. And it does so quite nicely. It is very well designed for this purpose. However it does provide facilities that allows the libraries to become arguably complicated, especially if you are not used to them. But being unfamiliar with a library's API is not really the same thing as the language being unreadable or obfuscated.

ericssmith··on It will take a 'baby elephant' to knock over this bike [video]
A motorcycle turns by 'falling over'. For me, that and the acceleration are the main attractions. Can't imagine this will get many motorcyclists to convert.
ericssmith··on Functional Programming Principles in Scala starts today
"I ask because my brain really cant absorb too many languages,... the next 5 years outlook."

Well, the early days of computing had domain specific languages, and I'm afraid we are getting back to that. The days of a one-size-fits-all language are over. Your best bet is to learn the principles and then the syntax differences just aren't that troublesome. The problem is that when you are new to programming, you learn only a small subset of those principles, and then are stumped when it is time to pick up a new language because it may rely on new concepts.

In education, Scheme once occupied the role of being the language in which you could learn and investigate a broad range of principles of computation. However, the perceived need for vocational training seems to have pushed Scheme out of the curriculum.

Today, Haskell is the best choice for this role.

ericssmith··on Functional Programming Principles in Scala starts today
I got it to work by using the 'nightly build' for Juno

http://scala-ide.org/download/nightly.html#scala_ide_helium_...

← PreviousPage 3 of 4Next →