Home » CSS » Css miscellaneous » Question
  1. Which of the following will select every

    element that is the only child of its parent?

    1. :optional
    2. :out-of-range
    3. :only-of-type
    4. :only-child
    5. None of these
Correct Option: D

:only-child selects every <p> element that is the only child of its parent, :only-of-type selects every <p> element that is the only child of its parent, :optional selects input elements with no “required” attribute.



Your comments will be displayed only after manual approval.