what is wrong with my script

var TheDamage : int = 50;
var Distance : float;

function update ()
(
   if (Input.GetButtonDown("fire1") )
   
       var hit : RaycastHit;
       if (Physics.Raycast (transform.position, transform.TransformDirection(Vector3.foward, hit) )
   {
            Distance = hit.distance:
            hit.transform.SendMessage("ApplyDamage", TheDamage, SendMessageOptions.DontRequireReciever);
        ) 
    }    
)

Lines 5, 6, 13 and 15 are meant to have braces, not parentheses. Parenthesis as end of line 6 is meant to be an opening brace.