error message for var

I am getting a very weird error message. all I need to have on a script is


function Update() {

And I get an error message that says "Unexpected token: var" or "expecting EOF found: var"

I've tried opening a new project and that didn't work. I even uninstalled Unity and reinstalled it. Am I just stupidly making a mistake, or is there something wrong with my unity program??

"var" declares a variable, you need a name after it.

Just delete the word "var", and your script will compile.

But what are you trying to do?