Interjection: a word most commonly used in dire, stressful, or really intense situations. Can also be used when one is very pissed off.
When the tree fell on Jesus' car, he yelled, "goddamit!!!"
"While I was driving home, I nailed this squirrel at 50mph. Goddamit, now I gotta clean the shit off my car!!"
Teacher: "OK class, your first midterm is tomorrow."
Dr. Evil: "So what'll it be, Mr. Powers? Save your girlfriend, or save your mojo?"