For all problems that involve writing queries or rules, test your solutions. To run the query system and load in the sample data:
> (load "~cs61a/lib/query.scm")
> (initialize-data-base microshaft-data-base)
> (query-driver-loop)
You're now in the query system's interpreter. To add an assertion:
(assert! (foo bar))
To add a rule:
(assert! (rule (foo) (bar)))
Anything else is a query.