added document.write so that user can see results on screen