Answer:
no
Step-by-step explanation:
If m, h, b represent the numbers of students in Mr. Smith's math, history, and both classes, then we have ...
m + b = 17
h + b = 15
m + b + h = 25
Adding the first two equations and subtracting the third gives ...
(m+b) +(h+b) -(m+b+h) = (17) +(15) -(25)
b = 7 . . . . . . simplify
The number enrolled in both of Mr. Smith's classes is 7, not 12.
_____
Here, m and h represent the number of students enrolled in only one of Mr. Smith's classes, math or history, respectively.