found this question on a website , it gives the answer as 0.27

but it doesn't show how the author arrived at the answer

ive never dealed with replacement before

A bag contains5 yellow beadsand5 blue beads(all identical apart from the colour).

7beads are drawn randomly from the bag, each being replaced before the next is drawn.

Calculate the probability that

Exactly 4 of the beads drawn are yellow

7! / 4! 3! = 35 * multiplied by 0.5 seven times= 0.2734

I dont know if the formula used is correct

or i simply got lucky and matched authors answer ?