When you subtract 10 from 22, the difference would be 12. This means that there are 12 beans that are either sweet or red. Another statement was that, there are 8 sweet jelly beans and 6 red jelly beans. However, if you total everything, 8+6+10, the sum would be 24. That would be more than the total number of beans in the bag which is 22. So, this means that 2 of those beans are sweet jelly beans and they are already included in the count for either the 8 or 6 sweet and red jelly beans, respectively.
The answer would be 2 sweet red jelly beans.