Javascript function alert is undefined
I am calling the function:

    checkScroll("rating");

I have this function:

    function checkScroll(param) {
      alert(param);
    }

Why is the alert undefined? 
Javascript function alert is undefined
===

I am calling the function:

    checkScroll("rating");

I have this function:

    function checkScroll(param) {
      alert(param);
    }

Why is the alert undefined? 