destroy rigidbody on collision js

i have the rigidbody destroying after 5 seconds but i dont know what to add to get the rigid body to destroy on collision
heres the script so far
var bullet : GameObject;

function Start () {

}

function Update () {

   
   Destroy(gameObject,5);

}

Try these two functions in one script, hung on your bullet prefab:

function Awake ()
{
	Destroy(gameObject, 5);
}
	
function OnCollisionEnter(col : Collision)
{
	if(col.gameObject.tag == "yourEnemyNameHere")
	{
		Destroy(gameObject);
	}
}

Awake thing does whatever you need after the object appears in game.