In a department store, there were a certain number of red T-shirts, blue T-shirts, and yellow T-shirts. 3/7 of the T-shirts were red, 1/3 of them were blue and the rest were yellow. If there were 20 more red T-shirts than blue T-shirts, how many yellow T-shirts were there?

50

Let's denote the number of red T-shirts as R, the number of blue T-shirts as B, and the number of yellow T-shirts as Y.

From the given information, we can create the following equations:
1) R = B + 20 (there were 20 more red T-shirts than blue T-shirts)
2) R + B + Y = Total number of T-shirts (since all T-shirts combined make up the total number)

We also know that:
3) 3/7 of the T-shirts were red, so R = 3/7 * Total number
4) 1/3 of the T-shirts were blue, so B = 1/3 * Total number

Using equation 2, we can substitute R and B with their respective values from equations 3 and 4:
(3/7 * Total number) + (1/3 * Total number) + Y = Total number

Simplifying the equation:
(9/21 * Total number) + (7/21 * Total number) + Y = Total number
(16/21 * Total number) + Y = Total number
(16/21 * Total number) = Total number - Y

Now, we can solve for Y:
Y = (Total number - Y) * 21 / 16

To find the value of Y, we need to know the total number of T-shirts.

To solve this problem, let's work step by step:

Step 1: Assign variables for the unknowns.
Let's assume the number of red T-shirts as R, the number of blue T-shirts as B, and the number of yellow T-shirts as Y.

Step 2: Translate the given information into equations.
From the information given, we can form three equations:

Equation 1: 3/7 of the T-shirts were red
This can be expressed as (3/7)(R + B + Y) = R

Equation 2: 1/3 of the T-shirts were blue
This can be expressed as (1/3)(R + B + Y) = B

Equation 3: There were 20 more red T-shirts than blue T-shirts
This can be expressed as R = B + 20

Step 3: Solve the system of equations.
To solve the system of equations, we can use substitution or elimination method. Let's use substitution method:

Substitute equation 3 into equations 1 and 2:

(3/7)(B + B + 20 + Y) = (B + 20)
(1/3)(B + B + 20 + Y) = B

Simplifying these equations:
(3/7)(2B + 20 + Y) = B + 20
(1/3)(2B + 20 + Y) = B

Multiplying through by the denominators:
(6/7)(B + 10 + Y) = B + 20
(2/3)(B + 10 + Y) = B

Simplifying further:
6(B + 10 + Y) = 7(B + 20)
2(B + 10 + Y) = 3B

Expanding:
6B + 60 + 6Y = 7B + 140
2B + 20 + 2Y = 3B

Simplifying again:
6Y - B = 80 ----(4)
2Y - B = 20 ----(5)

Step 4: Solve the remaining equations.
Now, let's solve equations (4) and (5) to find the values of Y (yellow T-shirts) and B (blue T-shirts):

Adding equation (4) and equation (5), we get:
6Y - B + 2Y - B = 80 + 20
8Y - 2B = 100

Now, substitute the value of B from equation (3) into the above equation:
8Y - 2(B + 20) = 100
8Y - 2B - 40 = 100
8Y - 2B = 140 ----(6)

Comparing equation (6) with equation (4), we see that both have the term -2B. Therefore, we can equate the coefficients of B:

-2B = -B
-2 = -1

So, B = 2.

Substituting this value of B into equation (5):
2Y - 2 = 20
2Y = 22
Y = 11

Therefore, there were 11 yellow T-shirts in the department store.