checking a global var

ok I'm trying to set up a global var canshoot that says when its true allow to shoot when its false don't allow to shoot so how do I declair a global var and then how do I check a var

http://unity3d.com/support/documentation/ScriptReference/index.Member_Variables_26_Global_Variables.html

c#

public class example : MonoBehaviour {
    public static int someGlobal = 5;
}

Reference by someGlobal from within script or by example.someGlobal from outside.

javascript

static var someGlobal = 5;

Reference by someGlobal from within script or TheScriptName.someGlobal from outside.