How to decrease a number by 1 every second?

Hey, so I put together this code, it’s fairly simple but I doesn’t work. Instead of going down by 1 every second it goes to 0 with in 2 seconds. How do I fix it?

#pragma strict

var health : String = "Health: ";
var hunger : String = "Hunger: ";
var thirst : String = "Thirst: ";
var sleepiness : String = "Sleepinees: ";

var hungerLevel : int = 100;
var thirstLevel : int = 100;
var sleepinessLevel : int = 100;

var speed : int = 1;


function OnGUI()
{
	GUI.Box (Rect (0,Screen.height - 25,100,25), health);
	GUI.Box (Rect (110,Screen.height - 25,100,25), hunger);
	GUI.Box (Rect (220,Screen.height - 25,100,25), thirst);
	GUI.Box (Rect (330,Screen.height - 25,110,25), sleepiness);
}

function Update()
{
	hungerLevel -= Time.deltaTime * speed;
	thirstLevel -= Time.deltaTime * speed;
	sleepinessLevel -= Time.deltaTime * speed;
	
	hunger = "Hunger: " + hungerLevel;
	thirst = "Thirst: " + thirstLevel;
	sleepiness = "Sleepiness: " + sleepinessLevel;
{

Use a coroutine.

#pragma strict

var num : int = 100;

function Awake()
{
	CountDown();
}

function CountDown()
{
	while(true)
	{
		
		num -= 1;
		yield WaitForSeconds(1);
	}
}

function OnGUI()
{
	GUILayout.Label(num.ToString());
}

You can achieve it using a recursive co-routine which will decrease a no every second. See below Code Sample.

int nos = 100;
void Start ()
{
	StartCoroutine ("descreseNos");
}

IEnumerator descreseNos()
{
	yield return new WaitForSeconds(1F);
	nos -= 1;
	StartCoroutine ("descreseNos");
}