What do you do to combat lonliness, boredom and hopelessness?

Help others . If that doesn't help there may be a neuro chemical issue that may need a temporary solution with medications.Long term solution is counseling to figure out past hurts or unsettled issues that need to be addressed.