circle_shape.cpp 137 B

12345678910
  1. #include "circle.h"
  2. namespace ShapeImpl
  3. {
  4. double area(const Circle &circle)
  5. {
  6. double r = circle.radius;
  7. return 3.14 * r * r;
  8. }
  9. }