Sublime Text
<!DOCTYPE html> <html> <head> <style type="text/css"> div p:last-child{ background-color:yellow; } </style> </head> <body> <div> <p>Hướng dẫn học lập trình web 1</p> <p>Hướng dẫn học lập trình web 2</p> </div> <div> <p>Hướng dẫn học lập trình web 3</p> <span>Hướng dẫn học lập trình web 4</span> </div> <div> <p>Hướng dẫn học lập trình web 5</p> <span>Hướng dẫn học lập trình web 6</span> <p>Hướng dẫn học lập trình web 7</p> </div> </body> </html>
<!DOCTYPE html> <html> <head> <style type="text/css"> div p:last-child{ background-color:yellow; } </style> </head> <body> <div> <p>Hướng dẫn học lập trình web 1</p> <p>Hướng dẫn học lập trình web 2</p> </div> <div> <p>Hướng dẫn học lập trình web 3</p> <span>Hướng dẫn học lập trình web 4</span> </div> <div> <p>Hướng dẫn học lập trình web 5</p> <span>Hướng dẫn học lập trình web 6</span> <p>Hướng dẫn học lập trình web 7</p> </div> </body> </html>