A bag contains 6 red marbles, 6 purple marbles, and 6 yellow marbles. What is the probability of randomly selecting a yellow marble from the bag?

The total number of marbles in the bag is 6 + 6 + 6 = 18 marbles.

Since there are 6 yellow marbles in the bag, the probability of randomly selecting a yellow marble is 6/18 = 1/3 or approximately 0.3333 or 33.33%.