Lessons
Scheme · Medium
Scheme · Medium. Ten lessons. Open-book quizzes. Lesson 1 free.
10 lessons · The Host · Lesson 1 free
Pass all ten lessons for the certificate. Sample · Claim

Lesson 1 · On the house
Pattern matching with ice-9 match
Destructure lists, pairs and trees with match; use predicates, or-patterns, ellipsis and dotted tails in one expression.

Lesson 2
Regular expressions with ice-9 regex
Match, capture, scan and rewrite strings with Guile regexps: string-match, list-matches, regexp-substitute/global and make-regexp.

Lesson 3
Vectors, SRFI-4 numeric vectors and arrays
Store dense data in vectors and SRFI-4 numeric vectors; build rectangular multi-dimensional arrays with array-ref, array-set! and array-dimensions.

Lesson 4
String ports, soft ports and binary pipelines
Capture output in strings, feed readers from string ports, build soft ports with write-string hooks, and move bytes through bytevector ports.

Lesson 5
Threads, mutexes and futures
Spawn threads with call-with-new-thread, protect shared state with mutexes, coordinate with condition variables, and parallelise with futures and par-map.

Lesson 6
syntax-case macros, hygiene and datum->syntax
Write procedural macros with syntax-case, compare them to syntax-rules, inspect syntax objects, and use datum->syntax only when you mean to break hygiene.

Lesson 7
Delimited continuations with prompts
Bound control with call-with-prompt and abort-to-prompt; resume the captured continuation or replace it, and use % / abort for the default prompt.

Lesson 8
Weak hash tables, weak vectors and guardians
Hold objects without preventing collection using weak-key and weak-value tables, weak vectors, and guardians that hand objects back after they die.

Lesson 9
Calling C with the foreign function interface
Load libc with dynamic-link, wrap symbols via pointer->procedure, pass pointers and ints, and pack structs with make-c-struct / parse-c-struct.

Lesson 10
PEG parsers and the compiler tower
Define PEG patterns with define-peg-pattern, match strings into trees, and evaluate Scheme forms through compile and lookup-language.
Sample certificate
Certificate of completion
Sign in to claim your certificate of completion.
Certificate
Finish all ten lessons, then sign in
Pass every lesson on this device (quizzes and checks). Then sign in or create an account to type your name and download the JPG.