By class name</span>
elements_by_class = driver.find_elements(By.CLASS_NAME, "element-class")

<span class="code-comment"># By CSS selector</span>
element_by_css = driver.find_element(By.CSS_SELECTOR, "div#main > p.intro")

<span class="code-comment"># By XPath</span>
element_by_xpath = driver.find_element(By.XPATH, "//div[@id='main']/p")

<span class="code-comment"># Extract text and attributes</span>
text = element_by_id.text
attribute = element_by_id.get_attribute("href")

<span class="code-comment"># In