Intro to Being a Purely Procedural Schemer
Try and create a few functions in Scheme, especially recursive ones
INTRODUCTION: Scheme is a lightweight, fast, and powerful language. Prepare to get your car and cdr on! One of the features is it is programmed recursively, which will truly allow you make some very creative programs. On the other hand if you are weak with recursion and its concepts it will force you to become better at it, and will only benefit from it.
- Hello World (see below)
- String Manipulation
- Discrete Math Concepts (patterns and logic)
- Display Pascal's Triangle
- Custom Collections & Sorting algorithms
- CGI scripts
IDE & Complier: DrScheme (~26Mb) (a.k.a. PLT Scheme)
If you have any questions Dream.In.Code does not have a language specific forum, however the do have a Functional Programming Forum, BUT Dream.In.Code does have Snippets!
HOW TO GET STARTED:
The official site for DrScheme has a very good getting started page: http://docs.plt-scheme.org/quick/
I suggest setting your language to: R5RS, its a pretty standard one
Just remember you can work right from the pompt, or you can save a .scm file and run your program from there. Try and build a library of functions to use!
Quick Start at what Hello World looks like:
;Your first program (begin (display "Hello, World!") (newline) )
Next Step is mastering the 3 C's; car cdr and cons. Take a look what happens, what is saved? how is it displayed?
(define numbers (cons 1 (cons 2 3))) (display (car numbers)) (newline) (display (cdr numbers)) (newline) (cons numbers (car numbers)) (display numbers)