The sentence in which the word but is used as a preposition is C) None but the brave shall enter in.
This is true because the word but can be replaced with the preposition except, which means it is also a preposition.
In the rest of the sentences, but is used as a conjunction.