Nope. One, the car would have to slow down, if the terr'ists want to hit anything. Two, they'd stick the gun out of the window so as not to go deaf. Three, shooting from a car is difficult even under the best of conditions. Four, nothing says you (the armed citizen) will be the primary/first target, in which case returning fire will be much easier.
It's not a fool proof method of preventing X percentage of terror attacks. It's a method of not being scared, of being willing to fight back. Of governments not hindering those of their citizens who are willing and able to defend themselves and those around them. There is no way, aside from a massive Big Brother state which would limit all freedoms, to prevent all the attacks. And a ridiculously small amount of people dying to terrorism annually is not cause enough to sell away your freedom. So that's an important distinction to make it. It's not so much that having armed citizens will prevent the majority of attacks, it's a mindset thing. "Attack us if you will, but we'll fight back, we won't be afraid, and we won't be easy targets."
Terrorism feeds off of the panicky sheep fear. It's useless against a society that is not afraid.
The prices are high and fear is the central concept.
Going back the specific example though, no, you couldn't defend against a sneak attack like that. They would not play it fair and take aim when you are paying attention. And they would likely be away before you unholstered your weapon.
Furthermore if someone did take out the attacker, well that's just one more martyr. Loss of life doesn't matter on that side.
I'm not sure how great guns are for not being so afraid. The principal risk would still always be there, and if armed citizens rendered some type of attack too likely to fail, at most it would mean a change of tactics for terrorists, probably back to these suicide bombings that just happened.