Uncle Fyodor is making sandwiches with sausage, while Matroskin and Sharik eat them. It is known that Matroskin ate three times more sandwiches than Sharik, Sharik ate 21 sandwiches less than Uncle Fyodor made, and Uncle Fyodor made twice as many as Sharik and Matroskin ate together. How many sandwiches did Uncle Fyodor make in total?
The first method. Let Sharik eat one part of all the sandwiches, then Matroskin ate 3 such parts, and together they ate 4 parts (see the figure). Therefore, Uncle Fyodor made 8 parts, which is 7 parts more than the number of sandwiches Sharik ate. Since these 7 parts make up 21 sandwiches, one part is three sandwiches. Thus, Uncle Fyodor made 24 sandwiches in total.

![](https://cdn.mathpix.com/cropped/2024_05_06_1aa9346639cd54e59f2ag-18.jpg?height=189&width=1104&top_left_y=1000&top_left_x=477)

The second method. Let Sharik eat \( x \) sandwiches, then Matroskin ate \( 3x \) sandwiches, and together they ate \( 4x \) sandwiches. Uncle Fyodor made \( 2 \cdot 4x = 8x \) sandwiches. Knowing that this is 21 sandwiches more than what Sharik ate, we can set up the equation: \( 8x - x = 21 \), from which \( x = 3 \). Thus, Uncle Fyodor made 24 sandwiches.

## Answer

24 sandwiches.