As the name suggests, the
name property holds the name of the current window and also enables you to give a window a name.
Let’s assign a name to a window then write it into the body of the page.
window.name = "The_No_1_Window"; document.write("The name of this window is "+window.name+" which is a great name!");