Gun obviously and without a question...
If you choose the gun, you're not getting shot, and who do you think the other two would go for? Who in his right mind would chose to attack a guy with a gun over a guy with a knife\pipe?
I would wait for knife vs pipe match up winner and i would kill him.
If some idiot try to attack me first, i would put a bullet in his head a proceed to pick up his knife\pipe.