What should I do it says me to add background color in the div class"The div element with class blue should have a background-color of blue." It says this

Tell us what’s happening:

Your code so far


<style>
body {
  background-color: #FFFFFF;
}
.blue {
  background-color: #000000;
}
.yellow {
  background-color: #000000;
}
div {
  display: inline-block;
  height: 100px;
  width: 100px;
#0000FF
</style>
<div class= "background-color :#0000FF"></div>
<div class ="background-color:#FFFF00"></div>

Your browser information:

User Agent is: Mozilla/5.0 (Linux; Android 10; SM-A505F) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.127 Mobile Safari/537.36.

Challenge: Learn about Complementary Colors

Link to the challenge:

Hello there.

Do you have a question?

If so, please edit your post to include it in the Tell us what’s happening section.

The more information you give us, the more likely we are to be able to help.

Hi @pragnya1132

A class name in css has a dot in front of it like this .green

When you assign this class to an DIV element it looks like this <div class="green">

Your style for the DIV element is broken it is missing a closing bracket they look like this } also you have added a color to the div style, this is not in the lesson and will fail the test.

Let me know if this helps

Regards Martin

Hi, hope you are doing well . I have understood your question . There is nothing wrong with color code the only thing is that u dont have to change class name of div element u have to change background color in style tag in respective classes . I think u should review lessons about adding CSS to html file.

<!--   For example this is how you will change the background color of div element of class name "my-div" to yellow    -->
<style>
 .my-div {
          background-color:#ffff00;
 
}
 </style>
 <div class = "my-div"> 
 </div>