DEC (HL)

Operation

(HL) <- (HL) - 1

Mnemonic

DEC

Operands

(HL)

b7b6b5b4b3b2b1b0
0 0 1 1 0 1 0 1$35

Description

The byte contained in the address specified by the contents of the HL register is decremented.

Condition Bits Affected

Sis set if result is negative, otherwise it is reset.
Zis set if result is 0, otherwise it is reset.
His set if borrow from bit 4, otherwise it is reset.
P/Vis set if (HL) was $80 before operation, otherwise it is reset.
Nis set.
Cis not affected.

Example

If the HL register pair contains $3434 and address $3434 contains $82, then upon the execution of

	DEC	(HL)

memory location $3434 contains $81.