4 ms·
To Scheme, or Not to Scheme
- idoh 17y agoIt depends on what you want to use it for. I've found that doing exploratory web development in Scheme is really painful. You are basically on your own, and have to develop everything from scratch. For example, if you want to make a simple get request from the twitter API and examine the results, you've got to be prepared to do a lot of work in extracting it out (unless you are a scheme guru). If you want to authenticate with OAuth, good luck with that, you'll have to write your own OAuth library from scratch.
- wingo 17y agoI really love web development in Scheme. Granted, that's only things on my site, which don't depend on money or anything -- but they were really fun to hack. But your comment regardin OAuth is poignant. I kinda wanted to implement it, saw the specs, and decided it would be too difficult. On the other hand, since my software is one-of-a-kind, I don't get any spam at all.
- idoh 17y agoAgreed. I've been playing around with web development with Scheme and Arc, and it really is a joy to use. Do you have any sites that are live right now that run scheme?
- wingo 17y agoOnly mine, http://wingolog.org/ http://wingolog.org/. The blog server is Scheme with a git backend, documented at http://wingolog.org/software/tekuti/ http://wingolog.org/software/tekuti/. The static bits of the site are generated from SXML.
- idoh 17y agoNice. I like how each page links back to the source that generated it.
- GeneralMaximus 17y agoSome people might find playing with programming languages a fun exercise, but many of us just want to build shit that works. Scheme might be the best thing ever, but the two operating systems I develop on have native APIs written in Objective-C and C++, respectively. (If you're wondering, the two operating systems I'm talking about are Mac OS X and Haiku.) IMO, Python is a great choice. Simple, clean language with a ton of APIs. I'm sure 90% of people out there will prefer hacking together quickie games using Python and PyGame to playing with continuations in Scheme. PS: I don't wish to imply that Scheme is a bad programming language. In fact, I've been mucking about with Scheme for the past week or so.
- _phred 17y agoScheme has always been interesting to me. It gets really interesting when you have a Scheme with a C FFI, as discussed here: http://jlongster.com/blog/2009/07/19/gambit-scheme-app-development/ http://jlongster.com/blog/2009/07/19/gambit-scheme-app-devel... Using the FFI, I could write my application code, low-level graphics calls, etc. in C or C++ or Objective-C, and call into my Scheme code at appropriate points. Gambit Scheme, discussed in that article, has a remote debugger as well, which has its own set of interesting possibilities. I guess I'm thinking mostly of Scheme for games and simulations, which seem more natural to me to express with a clean functional language like Scheme.
- jcl 17y agoOf course, if you wanted to hack together a language that compiled a single source to both Objective-C and C++, Scheme would be a pretty good environment in which to prototype it.
- wingo 17y agoTo Scheme.
- wingo 17y agoTough crowd, eh.
- b-man 17y agoI think the author needs to keep in mind the audience of HTDP: "everyone should learn how to design programs."[1] It is a book for a first semester not only for a CS curriculum, but for several other courses and styles. "So why should anyone learn to program? The answer consists of two parts. First, it is indeed true that traditional forms of programming are useful for just a few people. But, programming as we the authors understand it is useful for everyone: the administrative secretary who uses spreadsheets as well as the high-tech programmer. In other words, we have a broader notion of programming in mind than the traditional one. We explain our notion in a moment. Second, we teach our idea of programming with a technology that is based on the principle of minimal intrusion. Hence our notion of programming teaches problem-analysis and problem-solving skills without imposing the overhead of traditional programming notations and tools."[1] If you are already a programmer, there is a commentary from Matthias Falleisen about how you should read the book: "If you are an experienced programmer, you should read HtDP like this: -- read the sections whose title starts with "Designing ...." -- also read the "iterative refinement" sections -- pick five exercises in the preceding and/or follow-up sections and solve them according to the recipe -- unless you're stuck move forward -- try to understand the "symmetry" between data definitions and templates I expect that somewhere around late part II, you will slow down. You may pick up real reading as of part III, though some may make it thru III and only "stutter" in IV. Also: -- use check-expect to express your examples/tests -- avoid draw.ss exercises, replace them with world.ss but that's a non-trivial switch " [2] [1] http://htdp.org/2003-09-26/Book/curriculum-Z-H-2.html http://htdp.org/2003-09-26/Book/curriculum-Z-H-2.html [2]http://groups.google.com/group/plt-scheme/browse_thread/thread/1336829dca78089b/167c9643e187d265 http://groups.google.com/group/plt-scheme/browse_thread/thre...