Ex 17


#1


I'm stuck at this exercise : https://www.codecademy.com/courses/web-beginner-en-WF0CF/3/4?curriculum_id=50579fb998b470000202dc8b#


It seems like i followed all instructions but it doesn't work?


HTML CODE : 
<!DOCTYPE html>
<html>
	<head>
		<link type="text/css" rel="stylesheet" href="stylesheet.css"/>
		<title></title>
	</head>
	<body>
		<div>
			<p>I'm the first child!</p>
			<p>We're not.</p>
			<p>We're not.</p>
			<p>We're not.</p>
			<p>We're not.</p>
			<p>We're not.</p>
			<p>We're not.</p>			
		</div>
	</body>
</html>

CSS CODE:
/*Add your CSS below!*/
p:first-child{
    
    color:red;
    font-family:cursive;

}
p:nth-child(2){
    
    color:blue;
    font-family:Tahoma;
    
}
p:nth-child(3){
    
    color:#cc0000;
    
}
p:nth-child(4){
    
   background-color:#00ff00;
    
}
p:nth-child(5){
    font-size: 22px;
}


#2

Hello :slight_smile:

That is kind of strange and I don't really know how to explain this. In this part of code:

p:nth-child(4){
    
   background-color:#00ff00;
    
}

There is a special character placed after }, it looks like space, but it is (U+007F) Unicode character, let's call it evil space.

You need to delete it, or copy this code:

p:first-child{
    
    color:red;
    font-family:cursive;

}
p:nth-child(2){
    
    color:blue;
    font-family:Tahoma;
    
}
p:nth-child(3){
    
    color:#cc0000;
    
}
p:nth-child(4){
    
   background-color:#00ff00;
    
}
p:nth-child(5){
    font-size: 22px;
}

#3

sorry to interrupt but i just wanted to see the special character :slight_smile:


#4

I see, seems like removing the "evil space" seem to work out just fine.

Thank you!
Brian.


#5

You're very welcome! :slight_smile:


#6

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.