How do we do variable formatting using the <var> tag in HTML?

HTMLWeb DevelopmentFront End Technology

The HTML <var> tag is to format text in a document. It can include a variable in a mathematical expression.

Example

You can try to run the following code to do variable formatting using the <var> tag in HTML:

Live Demo

<!DOCTYPE html>
<html>
   <head>
      <title>HTML var Tag</title>
   </head>
   <body>
      <p>The equations: <var>2x</var> - <var>3z</var> = <var>5y</var> + 2 and
         <var>2x</var> + <var>5z</var> = <var>2y</var> + 7
      </p>
   </body>
</html>
raja
Published on 23-Apr-2018 16:51:10
Advertisements