Bag 1 contains 5 balls, 2 white and 3 black.
Let s note
P= number of favorable cases/ number of possible cases
Number of favorable cases is 2 because you extract 2 balls.
Number of possible cases is 5 which is number of the balls in the bag.
P= 2/5 = 40%.