Created
March 29, 2019 09:56
-
-
Save jasongorman/e8693b39914a3c85bea0ced2b0680a5c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ref(Carpet) c; | |
ref(Room) r; | |
ref(CarpetQuote) q; | |
r :- new RectangularRoom(2.5, 2.5); | |
c :- new StandardCarpet(10.0, False); | |
q :- new CarpetQuote(r, c); | |
OutText("Quote for rectangular carpet (not rounded) = "); | |
OutFix(q.quote, 5, 10); | |
Outimage; | |
c :- new StandardCarpet(10.0, True); | |
q :- new CarpetQuote(r, c); | |
OutText("Quote for rectangular carpet (rounded to nearest sq m) = "); | |
OutFix(q.quote, 5, 10); | |
Outimage; | |
r :- new CircularRoom(2.5); | |
c :- new StandardCarpet(10.0, True); | |
q :- new CarpetQuote(r, c); | |
OutText("Quote for carpet for circular room (rounded to nearest sq m) = "); | |
OutFix(q.quote, 5, 10); | |
Outimage; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment