Working for others, as well as, experiencing or sharing the hardships of their lives or situations, will help us understand and learn compassion for others. Doing this offers perspective, and will help you learn why people behave the way they do.
"For we are his workmanship, created in Christ Jesus unto good works, which God hath before ordained that we should walk in them." (Ephesians 2:10)
As you work, care, and love for others, this will also offer the opportunity for others to feel cared for. It also may offer them a break away from a hardship or routine, allowing them time to think about other ways to improve their situation instead of feeling drowned in it.