+ selector

Back to the index.

Selects an adjacent element.


pre + p {color: #CB000F;}

The pre + p selector means "each P element that is preceded by a PRE element". So this paragraph should be red and the other P's on the page shouldn't be.

This paragraph should not be red.


Insert paragraph after <pre>. Are all styles updated correctly?