Death and tragedy are a too-common part of life. The ability to write a good sympathy note allows you to express your feelings while comforting your friend at the same time. It is a simple matter to understand the technique of writing a sympathy letter. The difficult part is finding the right words to ease your friend's pain and to express your own feelings as well.
State the loss upfront and express your sympathy directly. Something like "I'm terribly sorry for your loss. You and your family are in my thoughts and prayers" is effective in this regard.
Mention special characteristics of the deceased. This is especially touching if you relate a story about you and the departed. Bring up something special she did or said that resonated with you.
Offer to assist in practical ways that you can follow through on. Gestures like bringing dinner or helping with planning or arranging events are much appreciated. Specifying a day that you are free to help makes it easier on the grieving friend to ask for your help.
Close by stating that you will miss the deceased as well. Then sign off with a phrase such as "Love" or "Your friend."