I write a script and when I run project it doesn't work.

I write script in Visual Studio code and when I run project script does not work.

Did you put the script onto an object? I recommend watching some YouTube tutorials to tech you about how unity handles scripts.

What is the code that is troubling you?