I have recently started following the examples from The Little Schemer and when trying out the examples in DrScheme, I have realised that there are some minor syntax changes from the examples in the book to what I can write in DrScheme.
First of all, as a language in DrScheme, I chose Pretty Big (one of the Legacy Languages).
Is this th...
I tried to write a (simple, i.e. without eqan?) one? function like such:
(define one?
(lambda (n)
((= 1 n))))
But the above doesn't work though because when I call it like such:
(one? 1)
I get greeted with this error:
procedure application: expected procedure, given: #t (no arguments)
The correct way (from The Little Sch...
Hi,
I'm a beginning student in CS, and my classes are mostly in Java. I'm currently going through "Little Schemer" as a self study, and in the process of finding out how to do that I have found numerous references to "implementations" of Scheme. My question is, what are implementations?
Are they sub-dialects of Scheme, or is that som...
Hi,
I'm going through the "Little Schemer" book, and doing the various functions. Generally I end up with the same version as the books, but not for eqlist?, which is a function to test the equality of two lists.
I've tried testing my version and it passes anything I throw at it. Yet it's slightly different from the "Little Schemer" ...
(define pick
(lambda (num lat)
(cond ((null? lat) (quote()))
((= (sub1 num) 0) (car lat))
(else
(pick (sub1 num) (cdr lat))))))
(define brees (quote (a b c d e touchdown g h i)))
(pick 6 brees)
The language in DrRacket is set to Advanced Student. It also works fine in the IronScheme...
So I just read The Little Schemer and found it really good! I had no prior functional programming background, apart from the "infamous" parenthesis myth I so much heard about Lisp :P
I found it an amazing read and now I'm starving for more. However, after searching a bit, I found this post about a Scheme Bookshelf. In that, the author s...