The Venn diagram is attached in the figure.
Total number of students = 32
Number of students have a dog = 0.5 *32 = 16
Number of students have a cat = (3/8) * 32 = 12
Number of students have other pets = 6
Number of students have no pets = 5
From the Venn diagram:
Number of students have a dog = x+y+z+10
Number of students have a cat = x+z+w+9
Number of students have other pets = y+z+w+2
Total number of students have no pets = 32 – (x+y+z+w+21)
So, as a conclusion for the above information
x+y+z+10 = 16 (1)
x+z+w+9 = 12 (2)
y+z+w+2 = 6 (3)
32 – (x+y+z+w+21) = 5 (4)
By solving the system of equations to find x , y , z , w
x = 2 , y = 3 , z = 1 , w = 0
By using Venn diagram
Number of students have all three types of pets = z = 1 student