News for hackers. Stuff that matters.
Re:Learn Physics by Programming in Haskell by tchow on Saturday February 24, 2018 @11:37AM (#16453976)
Can you share your experience with sicp? I'm self taught in JavaScript, go, python, ruby and taken Coursera for algorithms and read up on the operating system. Will sicp help me?
Re:Learn Physics by Programming in Haskell by jupiter90000 on Saturday February 24, 2018 @12:39PM (#16454306)
It had a nice way of solidifying certain (especially functional) programming concepts for me. However, one potential either annoyance or advantage to the book, depending on your perspective, is that it at times teaches relatively simple programming concepts by using what could be considered more difficult math problems.

For example, finding a square root using Newton's method and implementing the Fermat test in Lisp. Such problems could either be seen as fun or annoying depending on your background and/or enjoyment of learning this type of stuff in addition to programming concepts. They do tie in together nicely, it's just something I'd mention for someone looking into studying the book.

Re:Learn Physics by Programming in Haskell by AYBABTME on Sunday February 25, 2018 @10:51PM (#16462964)
I kind of randomly implemented Newton's method in Go once, just because it looks so pretty: https://github.com/aybabtme/newtonmethod#newtons-method
Re:Learn Physics by Programming in Haskell by shakna on Saturday February 24, 2018 @04:59PM (#16455675)
The SICP lectures are on YouTube [0], so you can grab a taste to see if you want it.

SICP covers a lot of the higher level concepts we use day-to-day, but in such a way that you can grasp lower-down concepts along the way.

That's let me write code faster, understand compiler stacktraces better, and grasp why some things work in a language, but similar code doesn't, and get a handle on optimisation where I need it.

Everyone seems to get a little different benefit out of it, but most people I know have got some benefit, even just from the first few exercises or lectures.

Unfortunately, it gave me my favourite area of CS: Language design. Which isn't exactly a career track, being so niche.

[0] https://www.youtube.com/playlist?list=PLB63C06FAF154F047

Re:Learn Physics by Programming in Haskell by Buttons840 on Saturday February 24, 2018 @12:15PM (#16454185)
SICP lives up to the hype in my experience. The pacing is perfect. It will take awhile to work through though. I'd suggest planning to skip some exercises and pick them up on a second read. Don't let yourself get bogged down and lose motivation over one exercise.
Re:Learn Physics by Programming in Haskell by fsloth on Saturday February 24, 2018 @12:01PM (#16454111)
I would recommend anyone who has not implemented an interpreter to implement the scheme interpreter in sicp (in any language of their choosing). At heart sicp is not about scheme but about computation systems in general and at that it's the most elegant book I've come across.
Re:Learn Physics by Programming in Haskell by bringtheaction on Saturday February 24, 2018 @03:32PM (#16455227)
Yes! SICP is, without a doubt, one of the very best books on programming I have ever read and I’ve read quite many. I too program a lot in JavaScript and Python (in addition to Rust and C and C++), so some might think SICP would not be relevant just because it’s using Scheme but in fact SICP has had a very significant impact on how I write software.

SICP is a book that I took my time to read. I read the whole thing front to cover. Some days I would read many pages some days fewer pages. I read a lot of it on a vacation. Don’t remember if I got through the whole thing then or if it took even more time.

SICP was so good that I plan on reading it again.

I recommend looking at the exercises and thinking about them a bit but like the other guy said don’t get bogged down by them.

Re:Learn Physics by Programming in Haskell by jonjacky on Sunday February 25, 2018 @09:59PM (#16462731)
I recently looked at SICP again after first reading it many years ago. I had retained the overall impression that SICP demonstrates how to build many of the celebrated creations of computer science - interpreters, compilers, databases, logic programming systems, circuit simulators - using a very simple programming language with just a few constructs.

But I had forgotten many of the details. Here is just one: in 3.1.1, Local State Variables, SICP shows how to, in effect, define classes and create objects using only function definition with lambda and set! (that is, assignment) in the definition body. The function you define this way is a like a class, the functions it returns are like instances. So you can do all this without any specifically object-oriented language features. This occupies just a few pages near the beginning of a long book - the whole book is dense with worked-out ideas like this.

The cumulative effect of all these examples in SICP is to demonstrate that you can solve any programming problem from first principles - that is, by combining a few simple but powerful constructs in the several ways they describe. Moreover, a solution constructed this way might be simpler and easier to understand than a solution made the more usual way: by looking for a specialized language construct or library that seems to offer an already-made solution to the problem.

Re:Learn Physics by Programming in Haskell by emmelaich on Saturday February 24, 2018 @10:51PM (#16457009)
One odd thing for me was that example problems seem to taken from physics and engineering. Which is natural for the authors and the time -- computer science departments typically started out as part of the Physics or Engineering departments.

One of the first examples is Newton's method for approximation. Which many beginning programmers have never encountered.

Re:Learn Physics by Programming in Haskell by Jtsummers on Saturday February 24, 2018 @11:26PM (#16457121)
In particular CS at MIT ~was~is in the EECS department. MIT also begins with calculus (18.01), not algebra or pre-calculus or anything else. Newton's method, at least in my undergrad (Georgia Tech, not MIT), did introduce Newton's method at some point (I cannot remember the context, but I do remember it in my first or second calculus course). Since SICP students would have taken or be taking Calculus at the same time, it wouldn't be a stretch for them to have seen those sorts of problems already.
Re:Learn Physics by Programming in Haskell by nikofeyn on Sunday February 25, 2018 @12:53AM (#16457375)
cs at mit is in the eecs department.
Re:Learn Physics by Programming in Haskell by Jtsummers on Sunday February 25, 2018 @01:08AM (#16457410)
Oops, yeah. That wasn't supposed to be past tense.
Re:Learn Physics by Programming in Haskell by nikofeyn on Sunday February 25, 2018 @09:41AM (#16459139)
haha. no worries. :)
Re:Learn Physics by Programming in Haskell by 0x445442 on Sunday February 25, 2018 @08:50AM (#16458925)
I posted the link elsewhere but if you take a look at this talk https://www.youtube.com/watch?v=O3tVctB_VSU it will give you an idea of where Sussman is coming from.

Also, I think right in the beginning of the very first lecture of the series Abelson talks about Computing as a way of codifying processes. In the link I included, Sussman says flat out that what he's interested in is using Computing as a better way to teach physics.

Re:Learn Physics by Programming in Haskell by billsix on Saturday February 24, 2018 @12:53PM (#16454372)
On Lisp by Paul Graham is more exciting and inspirational.

Sicp is solid fundamentals.

Read both.

Re:Learn Physics by Programming in Haskell by ChristianGeek on Monday February 26, 2018 @06:20AM (#16464557)
Here’s a link to modern versions of the code from “On Lisp.” The README includes a link to a (legal) PDF of the book and to Graham’s site:

https://github.com/DalekBaldwin/on-lisp/blob/master/README.m...

Re:Learn Physics by Programming in Haskell by professor_plum on Saturday February 24, 2018 @11:49AM (#16454061)
You might in fact love it. You'll get a nice overview of how interpreters actually work, for one thing.
Re:Learn Physics by Programming in Haskell by albertvila on Saturday February 24, 2018 @03:35PM (#16455240)
You can take a look at the book How To Design Programs (HTDP) [1]. It's similar. The 2nd edition printed book is going to be released soon [2]. There is a paper from the authors of HTDP comparing it to SICP [3]. By the way, there is an couple of online courses at EDX that covers content of HTDP [4][5].

[1] http://www.ccs.neu.edu/home/matthias/HtDP2e/

[2] https://www.amazon.com/How-Design-Programs-Introduction-Prog...

[3] https://en.wikipedia.org/wiki/The_Structure_and_Interpretati...

[4] https://www.edx.org/course/how-code-simple-data-ubcx-htc1x

[5] https://www.edx.org/course/how-code-complex-data-ubcx-htc2x