伪类都是为了解决一些技术难题特定产生的,CSS伪类是用来添加一些选择器的特殊效果。已经定义好的选择器,不能自定义。

常见的伪类选择器:nth-child、nth-last-child、nth-of-type、nth-last-of-type、first-child 、last-child 、first-of-type 、last-of-type、only-child以及only-of-type

另外,a标签也自带伪类选择器:
a:link、a:visited、a:hover、a:active