get variable from another script unity

C#
//Make Health public
public class PlayerScript: MonoBehaviour {
  public float Health = 100.0f;
}

//Access it.

public class Accessor : MonoBehaviour {
    void Start()
    {
        GameObject thePlayer = GameObject.Find("ThePlayer");
        PlayerScript playerScript = thePlayer.GetComponent<PlayerScript>();
        playerScript.Health -= 10.0f;
    }
}public class Script1 : MonoBehavior
{
public static int Script1Int;
}
//Another script:

public class Script2 : MonoBehavior
{
public static int Script2Int;

	void Start()
	{
    	Script2Int = Script1.Script1Int;
    }
}
Source

Also in C#: