Edit

How to Code CSS

Coding with CSS is too easy. Firstly you should select tag or id or class which you want to style and then add style using through style element or style attribute which we will study in further section. The property is a attribute of style element and value is the value of style attribute which is given by user.

Syntax-:

<style>
    selector { property: value }
</style>

Example of Code

<style>
.practice{ background-color: red; }
</style>
<p class="practice">CSS is used to style HTML document<p>

Output

CSS is used to style HTML document