How to call on collision enter only once

i have player which when collides with an enemy, the onCollisionEnter function is called.
I want that when it is called a heart should be destroyed.
also both the players are cubes.
This is the code for the onCollisionEnter method:

private void OnCollisionEnter(Collision collision)
    {
        if (collision.gameObject.name.Equals("player"))
        {
            heartscript.livesLost += 1;
            Debug.Log(heartscript.livesLost);
        }
    }

This is the code for heart script

public static int livesLost = 0;
    public GameObject heartOne, heartTwo, heartThree;
	
	void Update () {
        transform.Rotate(new Vector3(0,0,90)*Time.deltaTime);
        if (livesLost == 1)
        {
            Destroy(heartOne);

        }
        else if (livesLost == 2)
        {
            Destroy(heartTwo);

        }
        else if (livesLost == 3)
        {
            Destroy(heartThree);
        }
	}

Problem is that every collision the value of lives lost becomes 20 so in one collision only i lose all 3 LIVES
Any help would really be appreciated.
Thanks !!
Please!!

Try this (FYI: this uses the tag system, so tag the player with a “player” tag):

public class EnterOnceCollision : MonoBehaviour {
  private bool hasEntered;

  void OnCollisionEnter (Collision other) {
    if (other.gameObject.CompareTag("player") && !hasEntered) {
      hasEntered = true;
      heartscript.livesLost += 1;
      Debug.Log(heartscript.livesLost);
    }
  }
}

Ok you need To Use Both OnCollisionEnter And OnCollisionExit For it To Work
So Use like this :

bool Hitted;
private void OnCollisionEnter(Collision collision)
      {
          if ((collision.gameObject.name.Equals("player")) && (Hitted == false))
          {
              Hitted = true; 
              heartscript.livesLost += 1;
              Debug.Log(heartscript.livesLost);
             }
      }
private void OnCollisionExit(Collision collision)
{
if ((collision.gameObject.name.Equals("player")) && (Hitted ==true))
      {
         Hitted = false;
      }

}

Try create a bool var on your script where OnCollision is. Then you try it:

private void OnCollisionEnter(Collision collision)
     {
         if ((collision.gameObject.name.Equals("player")) && (colide == false))
         {
             //var created
            colide = true;
             heartscript.livesLost += 1;
             Debug.Log(heartscript.livesLost);
             //var created
             colide = false;
         }
     }

I think this will make the action happens once