Howdy, pramuk97.
The document object's write() method writes HTML markup to the document loaded in the browser. Your code equates to the following markup:
Load that in any browser, and you won't see a line break between "bob" and "tom". That's because a browser does not format text based on line feeds or whitespace (except for single spaces between words); text is formatted by using HTML elements. So when you want to format any text in a web page, you have to use HTML elements. What you want to do is this:
Code:
document.write("bob <br/> tom");