I cleaned up your code.
You need to use triple backticks to post code to the forum.
See this post for details.
Note that inline styles are considered a bad practice, but it works the same as with a separate stylesheet. You can just add new styles separated with a semicolon:
<h1 style="color:green; background-color:black">This is a heading</h1>