Quiz: CSS Selectors

Test your understanding of the concepts of CSS selectors.

We'll cover the following...
Technical Quiz
1.

Which pattern is used to get all the <a href="URL3"> elements in the given code snippet?

<div>
    <a href="URL1"></a>
    <ul>
        <li>
            <a href="URL2"></a>
        </li>
    </ul>
    <a href="URL3"></a>
</div>
A.

soup.select("div , a")

B.

soup.select("div + a")

C.

soup.select("ul + a")

D.

soup.select("div > a")


1 / 4