17 Language Gems I
17.1 Questionnaire Language (QL)
Matthew Flatt
#lang survey-dsl |
|
form Box1HouseOwning { |
hasSoldHouse: "Did you sell a house in 2010?" boolean |
hasBoughtHouse: "Did you by a house in 2010?" boolean |
hasMaintLoan: "Did you enter a loan for maintenance?" boolean |
|
if (hasSoldHouse) { |
sellingPrice: "Price the house was sold for:" money |
privateDebt: "Private debts for the sold house:" money |
valueResidue: "Value residue:" money(sellingPrice - privateDebt) |
} |
} |
17.2 Teachlog
Jay McCarthy
We will be walking through the implementation of a logic language in Racket. If you want to follow along with the code on your own machine, then see:
https://github.com/jeapostrophe/teachlog
We suggest, however, that you open your own buffer and implement it as we walk through it. If you do so, then you’ll want to put a directory named my-teachlog in the work directory you created for Wednesday’s activities. If you forgot how to create that, then see: