Ironically enough, you get gunpowder by killing the creepers

Very cool thanks!

But how do you kill creepers? They blow up pretty much as soon as they see you