Hacker News new | past | comments | ask | show | jobs | submit login

So my colleage recommended we look into spark, which looks pretty neat, but said a caveat would be that we would need to learn scala. My first impression of your bare minimum is "holy crap that's a lot of boilerplate for a bare minimum project". While I expected there to be some code necessary to get thing up and running, my mind spun at that 400loc build script. What the heck is that for if you are not actually doing anything? Also, I have some experience with lisp as a functional language...What are all this crazy symbols doing in your main scala file? :Unit=\n ?? I hate to be critical, but what on earth is going on here? It's not exactly welcoming, by any means.



You don't have to use the sbt script provided here.

It's just for convenience: it will automatically install Java, Scala and dependencies. Run it and you don't have to hunt down anything from the web.

If you have SBT already installed (with homebrew, MSI, apt-get etc), you don't need that file at all.

Main.scala is a "println", Build.scala sets some compiler flags and project name - this is all.

About "Unit": Scala is strongly typed. In exchange you will not have run-time type errors and also you don't need type checking unit tests.


Thanks for the response. Given it's going to the JVM I should have been more prepared for verbosity. I did a bit more reading and with your suggestions it seems my initial reaction is mostly just shock of a change from what I'm used to. I'll do some more research and will probably mellow out a bit :) Any suggestions on ebooks or otherwise to get started? Cheers!


I updated the README with some additional info.

Java and Scala have essentially the same bytecode output as both compilers were written by Martin Odersky.

There are many links below: free books, PDFs, articles, videos, tutorials.

Or just Google "The busy Java developer's guide to Scala" (article), "Scala for the impatient" (PDF), "A Tour of Scala", "An Introduction to Scala for Java Developers" (about REPL) etc.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: