CSS Rule can be written by the style attribute of the HTML element, inline css. Earlier in the HTML tutorial, I have used inline CSS in a number of places. Inline CSS should not be written if you do not need it too much. You should always use External CSS.

Since the CSS is written inside the element, there is no need for inline CSS. Such as

<h2 style="background-color: #f00; color: #fff;">A new background and
font color with inline CSS</h2>

There is a difference here that there are no selectors and there are no curly braces.

** Each line with a semicolon (;) is to be distinguished as I separated the two lines. Thus you can enter the property as many as you want.