Molecules that have a π bond between two different atoms will exhibit resonance, provide the atoms are different, having different electronegativities. They have the following general structure.
You will encounter this pattern many times in organic chemistry. This resonance typically indicates that the carbon connected to Z is deficient in electrons. You should be able to draw the resonance hybrid for these.
Take note of the following