Strike Text in HTML

When you need to make a thin line through the text, for that <strike> tag.
But in HTML5.2 draft, <strike> is an obsolete feature. So better use <del> tag istead of <strike> tag.

This is wrong line.
This is right line.


<!DOCTYPE html>
<html>
    <head>
    </head>
    <body>
        <p>
            <strike>This is wrong line.</strike>
            <br>
            This is right line.
        </p>
    </body>
</html>
                        

Superscript Text

Most of the times, when you are working with content related to Maths, superscript <sup> tag is used.
The content which is in <sup> tag will be over the other surrounding words at the half of the height of other words.

43 = 64

This is tagline with TMTM.


<!DOCTYPE html>
<html>
    <head>
    </head>
    <body>
        <p>
            4<sup>3</sup> = 64
        </p>
        <p>
            This is tagline with TM<sup>TM</sup>.
        </p>
    </body>
</html>
                        

Subscript Text

To make the word appear beneath the surroungin words, Subscript <sub> is used.
Practically while writing Chemical reactions in HTML, it will be very helpful.

NH3 + O2 => N2 + H2O


<!DOCTYPE html>
<html>
    <head>
    </head>
    <body>
        <p>
            NH<sub>3</sub> + O<sub>2</sub> => N<sub>2</sub> + H<sub>2</sub>O
        </p>
    </body>
</html>
                        

Conclusion

In this section, you have learned about formatting the content using Strike, Superscript, and Subscript.
In next section, you will learn about some less known formatting tags in HTML.