showing me error - document is not defined
I am totally nervous please help me
function myF(num){
if(num>2) {
document.write(“greater than 2”);
}
else if(num<2){
document.write(“less than 2”);
}
else{
document.write(“”)}
}
document.write(myF(2));