Input not working...

So I have this code attached to a game object and its code straight from the documentation.

if (Input.GetKeyDown(KeyCode.Space))
            print("space key was pressed");

I get this error, Input' does not contain a definition for GetKeyDown’…

Anyone know why?

I think I figured it out. I was using Input as the name of the script which I guess is a reserved keyword in unity. Their error message is not very helpful however…