Which CSS3 code fragment styles an H2 element only if it is a direct child of a DIV element?
A.
h2 > div {background-color: #900;}
B.
div, h2 {background-color: #900;}
C.
div {background-color: #900;}h2 {background-color: #900;}
D.
div > h2 {background-color: #900;}
Explanation:
https://www.w3.org/TR/CSS21/selector.html%23id-selectors
D. div > h2{}
New questions from September 2017 incoming:
http://optimumfiles.com/ProgrammingInHTML