-5

I want to display following output on browser. Please suggest me, how can I generate following output on browser output should :- <html>

I have used following code

 <html>
 <head></head>
 <body>
   <html>
  </body>
  </html>
Rakesh Shetty
  • 4,548
  • 7
  • 40
  • 79
harish
  • 13
  • 6
  • 1
    There are literally hundreds of answers to variations of "how to I escape HTML characters?" on stackoverflow. I suggest you try searching for an answer before asking a question. – Nicolas Rinaudo Aug 27 '14 at 12:27

3 Answers3

0

You need to escape < and > using entities:

&lt;html&gt;
Jakub Kotrs
  • 5,823
  • 1
  • 14
  • 30
0

Use &lt; and &gt; for < and >:

&lt;html&gt;
Patrick Hofman
  • 153,850
  • 22
  • 249
  • 325
0

You need to escape the HTML content you want visible to the user:

<html>
<head></head>
<body>
    &lt;html&gt;
</body>
</html>
Cᴏʀʏ
  • 105,112
  • 20
  • 162
  • 194