<html>
<head>
<style>
p:nth-last-child(odd) {
background: red;
}
p:nth-last-child(even) {
background: blue;
}
</style>
</head>
<body>
<p>The first paragraph.</p>
<p>The second paragraph.</p>
<p>The third paragraph.</p>
<p><b>Note:</b> Internet Explorer 8 and earlier versions do not support the :nth-last-child() selector.</p>
</body>
<!-- Mirrored from www.w3schools.com/cssref/tryit.asp?filename=trycss3_nth-last-child_odd_even by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 05 Jun 2019 14:27:58 GMT -->
</html>