5.1 the Z-flag

This is the easiest one. What does it mean when Z = 1 after a cmp instruction?

The only time a difference is zero is when the two operands are the same! As a result, the Z-flag is also sometimes known as the E-flag for “equal”.