The HTML5 documentation recommends putting the code element inside the pre element, but I don\'t understand how this is better or more semantic tha
To represent a block of computer code, the pre element can be used with a code element;
To represent a block of computer output the pre element can be used with a samp element.
for block code that must not wrap.
Use for inline code that can wrap.
Line breaks and white spaces in the text enclosed within the tags is maintained as it is in the html document when displays on the browser.Browsers normally render text in a fixed-pitched font, with whitespace.