Do you have someone IRL with which to discuss these sad and guilty feelings?
Suicide affects everyone around, and those not close just from hearing about it.

There's always the question of "What could I have done differently?" But in the final analysis, if a person is determined to end their life, they will eventually.
There has been too much in the news about young people completing suicide, and not enough about the accomplishments of those who are working hard at making a life for themselves, and a better community for the rest of us.
Take care of yourself during this fragile time--make sure you share your feelings, like you have here, with those in your life, ok?