document write

i decided that the best way to make a nice output is  by using JS
document.write. I am bit worried about the variables, but i believe at
the end we will have a nice result.