Step 1: Decode the given subnet mask.
The subnet mask provided is $255.255.255.252$, which represents a /30 network.
In a /30 subnet:
Step 2: List the subnet intervals.
Since the block size is 4, the subnets in the last octet progress as:
\[ 0\!-\!3,\; 4\!-\!7,\; 8\!-\!11,\; \ldots \]
Step 3: Identify the subnet for each machine.
Machine M:
IP address: 100.10.5.2
This address falls within the $0\!-\!3$ range.
Therefore, it belongs to the subnet:
\[ 100.10.5.0/30 \]
Machine N:
IP address: 100.10.5.5
This address lies in the $4\!-\!7$ range.
Hence, its subnet is:
\[ 100.10.5.4/30 \]
Machine P:
IP address: 100.10.5.6
This address also falls in the $4\!-\!7$ range.
So, it belongs to the subnet:
\[ 100.10.5.4/30 \]
Step 4: Compare subnet membership.
Machines N and P share the same subnet, whereas machine M is part of a different subnet.
Step 5: Final conclusion.
Only machines N and P are on the same subnet.