The output element speaks to the consequence of a computation.
The OUTPUT Element is one of the best feature of Form Elements, which allows user to make a calculation on the front end without involving much affords.
In these scenarios a lot of websites are featured with calculation systems as loan payment, inventory report, taxation and many more. There was no such way at the front end and with HTML to use this facility. But With the development of HTML5 now we can use these calculations easily with the OUTPUT Element of HTML5.
Here is the Syntax for OUTPUT Element
<output> . . . </output>
Below is complete syntax along with example
<!DOCTYPE html> <html> <head> <title>Title name will go here</title> </head> <body> <form onsubmit="return false" oninput="document.getElementById('o').innerHTML = parseFloat(document.getElementById('a').value) + parseFloat(document.getElementById('b').value)"> <input name="a" id="a" type="number" step="any"> + <input name="b" id="b" type="number" step="any"> = <output name="o" id="o" for="a b"></output> </form> </body> </html>