DEFB inserts the bytes following it (as many as you require) at the point it occurs in the program. I used bit representation here because it suits the purpose.Code:DEFB 01110010b, 11001001b
You'd then just load a byte at a time to one of the registers (register A, the Accumulator, would be the ideal one) and process each bit individually with the BIT instruction which sets or resets the zero flag according to the value of the bit tested.
You could even operate on 16 bits at a time and stored data with DEFW. The Z80 features register pairs which do provide some 16bit functionality. Loading data into them is as trivial as with 8 bit registers, But since BIT only operates on an 8 bit register (BIT n, r), there wouldn't be much gain here.