I always fear probability

A factory produces two types of shirt: shirt A and shirt B. Each type of shirt has 3 sizes: small (S), medium (M) and large (L). The number of shirt A produced and the number of shirt B produced are in a ratio 2:3. For each type of shirt, the number of shirts in S, M, L sizes are in the ratio 2:5:3

(a) If a shirt is chosen at random, find the probability that it is shirt A in S size.

(b) If a shirt is chosen at random and found to be size S, find the probability that it is shirt B.

2. Relevant equations

3. The attempt at a solution

(a) (2/5) x (2/10) (my approach is the proportion of shirt A multiply the proportion of small size, i don't know if it's true.)

(b) I think it is a conditional probablilty problem but i am not sure. I can construct the equation. It should be

P(shirt B | size S) = P ( B and S ) / P(S)

then i come into problem , i don't know what P(S) and P(B and S) should be.

Do you know that if you have N things, m of them fitting a given requirement, and one is chosen at random (all being equally likely) then the probability of it fitting that requirement is m/N? That's usually the first formula one learns about probability.
Now what you need to do is use those given proportions to get some numbers.

If "The number of shirt A produced and the number of shirt B produced are in a ratio 2:3" and there were 2+ 3= 5 shirts made, how many of them would be type A?

If there were 2+ 3+ 5= 10 shirts made, how many of them would be size S?

Now multiply that by 5: if there were 50 shirts made, how many of them would be size Z. And of those, how many would be type A? (Look back to the first question.)

That last number, divided by the total number of shirts, 50, is the probability a shirt chosen at random would be of type A and size small.

Do you know that if you have N things, m of them fitting a given requirement, and one is chosen at random (all being equally likely) then the probability of it fitting that requirement is m/N? That's usually the first formula one learns about probability.
Now what you need to do is use those given proportions to get some numbers.

If "The number of shirt A produced and the number of shirt B produced are in a ratio 2:3" and there were 2+ 3= 5 shirts made, how many of them would be type A?

If there were 2+ 3+ 5= 10 shirts made, how many of them would be size S?

Now multiply that by 5: if there were 50 shirts made, how many of them would be size Z. And of those, how many would be type A? (Look back to the first question.)

That last number, divided by the total number of shirts, 50, is the probability a shirt chosen at random would be of type A and size small.

Thanks for part (a)

how about part (b), given that they are in size S and look for probability to be in Shirt B

This is a common assumption with coin tosses. Say there's a coin that has P(Heads) = 1/2.

If you have A = {1st coin toss is heads} and B = {2nd coin toss is heads}, then P(A and B) = P(A)*P(B).

Knowing that the first coin toss is heads does not give you any information about what the second coin toss will be.

In this particular example, if someone picks a shirt and tells you it's small, you don't know whether it's type A or B. The given information does not change the probability. Also vice versa, if you know that it's type A or B shirt, that doesn't help you determine whether it's small, medium or large.