class Circle {
  constructor(public readonly radius: number) {}
}

class Square {
  constructor(public readonly length: number) {}
}

class AreaCalculator {
  constructor(private readonly shapes: object[]) {}

  public sum(): number {
    // Logique pour additionner les aires ...
    return 0;
  }

  public printSum(): void {
    const sum = this.sum();
    console.log(`Somme des aires : ${sum}`);
  }
}

const calculator = new AreaCalculator([new Circle(5), new Square(4)]);

calculator.printSum(); // affiche la somme des aires

export default {};
