Any martial art is better than no martial art, but there's nothing better than a gun. That being said, assuming we're talking about places where you can't have a gun:
Every martial art is good at a couple things. BJJ is only one small part of the overaching Samurai education. It's not going to be perfect alone, because it was never meant to be alone. BJJ is a ground-fighting art. But when you're in a fight,
especially a street fight, you
really do not want to be on the ground. BJJ is not some silver bullet to all of your self-defense woes.
Your best bet is to learn a variety of combat arts, to suit a variety of situations, if you're really worried about being jumped.
Generally though, if your goal is to learn to defend yourself (rather than just learning a combat sport for the love of the sport), you want to pick a combat sport which has historically been used either by guerilla fighters or by militaries.
The Marine Corps Martial Arts Program teaches
seventeen different fighting styles to every student. Which includes BJJ! But it's not
just BJJ.
Edit: there is a difference between B JJ and JJ. Jiu Jitsu is much, much better than BJJ. I still advocate a variety of fighting styles, but at least Jiu Jitsu will serve you reasonably well. BJJ on the other hand is one of the least useful martial arts in a real street fight