Child Selector
direct child between the div
direct child
no direct child
Paragraph 4 in the div.
not even a child
Descendant Selector
all p betwen div.
direct child and decendent
only decendent
only decendent
Not Descendant/ child
Adjacent Sibling Selector
The + selector is used to select an element that is directly after another specific element.
Paragraph 1 in the div.
Paragraph 2 in the div.
Paragraph 4. After a div.
Paragraph 5 in the div.
Paragraph 7. After a div.
Paragraph 8. After a div.
The general sibling selector (~) selects all elements that are next siblings of a specified element.
Paragraph 1.
Paragraph 2.
Paragraph 3.
Some code.
Paragraph 4.