You're right that a shotgun is a much better home defense weapon.
For community defense and armed protection outside the home, a handgun is ideal because it can be carried concealed. Definitely should use hollow points, to prevent pass-through that could hit others.
In any situation with guns, training is important. Connect with others who can help train you or look into classes in your area. Groups like the #SRA are useful and welcoming to beginners.