HTML sup tag
HTML sup tag
2024-08-21 18:58:36 - Sakala Code
HTML sup tag
Superscript text appears slightly above the normal line of text and is usually smaller. It is commonly used for mathematical notations, footnotes, or chemical formulas.
HTML sup tag with example
<!DOCTYPE html> <html lang="en"> <head> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Superscript Example</title> </head> <body> <h1>Using the Superscript Tag</h1> <p>square of a number:</p> <p>5<sup>2</sup> = 25</p> <p>10<sup>2</sup> = 100</p> <p><b>Chemical formulas use superscript</b></p> <p>H<sup>+</sup> (a hydrogen ion) or SO<sub>4</sub><sup>2-</sup> (a sulfate ion)</p> </body> </html>