All snakes have teeth and can bite. Non-venomous constrictors seize their prey in their six rows of sharp, recurved teeth and hold onto it whilst wrapping their coils around it. They then tighten their coils each time the prey breathes out, until it can no longer draw breath and suffocates. Venomous snakes, as well as having smaller teeth similar to a constrictor's, have fangs - two large hollow teeth at the front of the mouth, through which venom flows into whatever the snake is biting. In some species, such as cobras, the fangs are fixed, whereas in others, such as rattlesnakes, they are hinged, lying folded against the roof of the mouth until needed. Venomous snakes bite, inject venom, and instantly release their prey. They then track it whilst the venom kills it, and consume it when they find it dead.
When a constrictor bites in defence, it will not try to constrict - it only constricts something that it's going to eat. It will therefore bite and let go (though they sometimes have trouble letting go, since the recurved teeth hook into the flesh). Venomous snakes are capable of giving 'dry bites' in defence - that is, biting without injecting venom. Venom is valuable, and the snake needs it for killing its prey - it does not want to waste it on defence.
Remember that all snakes would rather avoid conflict than bite you. They are not out to get you. If you leave them alone, they'll leave you alone.