This is very very important.
This is really very important.
比如这个代码,我要让第二个h1下的strong元素变色,用什么选择器实现
比如这个代码,我要让第二个h1下的strong元素变色,用什么选择器实现
结构伪类选择符: 随你用哪个
E:nth-child(n):匹配父元素中的第n个子元素E;(span:nth-child(3))
E:nth-last-child():匹配父元素中倒数第n个子元素E
E:nth-of-type(n): 匹配父元素内具有指定类型的第n个E元素(span:nth-of-type(2))
E:nth-last-of-type(n):匹配父元素内具有指定类型的倒数第n个E元素