Task

Create two classes   Point(x,y)   and   Circle(x,y,r)   with a polymorphic function print, accessors for (x,y,r), copy constructor, assignment and destructor and every possible default constructors




(class +Point)
# x y
 
(dm T (X Y)
   (=: x (or X 0))
   (=: y (or Y 0)) )
 
(dm print> ()
   (prinl "Point " (: x) "," (: y)) )
 
(class +Circle +Point)
# r
 
(dm T (X Y R)
   (super X Y)
   (=: r (or R 0)) )
 
(dm print> ()
   (prinl "Circle " (: x) "," (: y) "," (: r)) )