1 2 package shapes; 3 4 import shapes.SCircle; 5 import shapes.SSquare; 6 7 public class YellowSpace { 8 public static void main(String[] args) { 9 double tableSide= 800.0; 10 double cornerTable= 80.0; 11 double insideCornerYellow= 40.0; 12 SSquare tables= new SSquare(tableSide); 13 14 double diameterBigCircle = tableSide - (cornerTable*2); 15 double radiusBigCircle= diameterBigCircle/2; 16 SCircle bigCircle= new SCircle(radiusBigCircle); 17 SSquare yellowSquare= bigCircle.inscribingSquare(); 18 19 double diameterSmallCircle= yellowSquare.side()- (insideCornerYellow *2); 20 double radiusSmallCircle= diameterSmallCircle/2; 21 SCircle smallCircle= new SCircle(radiusSmallCircle); 22 SSquare smallSquare= smallCircle.inscribingSquare(); 23 24 double yellowArea= yellowSquare.area()- smallSquare.area(); 25 System.out.println("the area of the yellow space in the tablecloth " + yellowArea); 26 27 } 28 } 29