All of these sentences are fine. The difference between the first two is the same as the general difference between the usage of "the" and "a".
You probably already understand this (I hope you do!), but, although there are a few minor exceptions, in general, "the" is used when the speaker has an expectation that the audience will understand the specific item being discussed. That is why it is referred to as a "definite article", as opposed to "a", which is an "indefinite article". "A" is used with singular, countable nouns when the speaker does not have an expectation that (or it isn't relevant if) the audience will understand the specific item being discussed.