Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
19
Task/Polymorphism/Inform-7/polymorphism.inf
Normal file
19
Task/Polymorphism/Inform-7/polymorphism.inf
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
Space is a room.
|
||||
|
||||
A point is a kind of thing.
|
||||
A point has a number called X position.
|
||||
A point has a number called Y position.
|
||||
|
||||
A circle is a kind of point.
|
||||
A circle has a number called radius.
|
||||
|
||||
To print (P - point): say "Point: [X position of P], [Y position of P]."
|
||||
To print (C - circle): say "Circle: [X position of C], [Y position of C] radius [radius of C]."
|
||||
|
||||
The origin is a point with X position 0 and Y position 0.
|
||||
The circle of power is a circle with X position 100, Y position 25, radius 7.
|
||||
|
||||
When play begins:
|
||||
print the origin;
|
||||
print the circle of power;
|
||||
end the story.
|
||||
Loading…
Add table
Add a link
Reference in a new issue