Think of it this way. Suppose one person is wearing both blue and green. How many people are wearing blue then? And how many people are wearing green? So how many total are there?
Well, if one person is wearing both, then five are wearing green. Why? one-fifth of those wearing green are _also_ wearing blue. In other words, one-fifth of those wearing green are one person. Similarly, eight are wearing blue. So in all there are 5+8-1=12 people. Finishing the question is straightforward from here but I trust you've figured it out by now.