To determine how many students in the sample prefer dogs, we need to consider both male and female students who prefer dogs as per the provided table.
From the table:
- The number of male students who prefer dogs is 36.
- The number of female students who prefer dogs is 20.
To find the total number of students who prefer dogs, we sum these two values:
[tex]\[ 36 \, \text{(male students who prefer dogs)} + 20 \, \text{(female students who prefer dogs)} = 56 \][/tex]
Thus, the total number of students in the sample who prefer dogs is:
[tex]\[
\boxed{56} \text{ students}
\][/tex]