Tryit Editor v2.3

Edit This Code:
<!DOCTYPE html> <html> <head> <style> p:only-of-type { background: #ff0000; } </style> </head> <body> <div><p>This is a paragraph.</p></div> <div><p>This is a paragraph.</p><p>This is a paragraph.</p></div> </body> <!-- Mirrored from www.w3schools.com/cssref/tryit.asp?filename=trycss3_only-of-type by HTTrack Website Copier/3.x [XR&CO'2014], Fri, 23 Jan 2015 08:14:06 GMT --> </html>
Result:
Try it Yourself - © w3schools.com