Observe from the figure,
\The set A contains 25 elements, then
.
The set B contains 20 elements, then
.
The common part of set A and set B contains 8 elements, then
.
The elements in the set A or set B is
.
Use counting formula :
.
Substitute
,
and
in the formula.

The elements in the set A or set B is 37.