I have got this result
which outputs a number alright. However, I d like to be a bit fancier and want to output it red if it is equal to 5 or smaller and green otherwise.
I know that you change color by document.write(fontcolor("red"))
but I dont know how to embed this last document.write etc into the one I have above