Often a hug is all they need.
"I'm sorry to hear that, if you need anything just let me know."
"I'm so sorry for your loss."
"I don't know what to say, I'm sorry to hear that."
You can say any variation of sympathetic response you want but often they're in such shock they won't remember a lot of what is said. Actions are more important. Go to funeral/wake, shake hands, offer kind words and hugs.
Just do nice things for them and be supportive. It's always hard but genuine love is always the best response.