Analog Devices Interview Question

Describe how a Comparator works