adplus-dvertising
frame-decoration

Question

Which of the following selector selects an element if it’s the only child of its parent?

a.

:root

b.

:nth-oftype(n)

c.

:only-child

d.

none of the mentioned

Posted under CSS

Answer: (c).:only-child

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Which of the following selector selects an element if it’s the only child of its parent?