I am confused about the function of the word "but" in given sentence what "part of speech" the word "but" is in the given sentence. I actually shared my opinions with my teacher about the word "but".
My opinions: The word " but" is an adverb in the given sentence because it modifies adjective "easy". Moreover, I looked it up in dictionary and it got something else "anything but" is also an idiom. Secondly, I checked it in Oxford Advanced Learner's Dictionary — the same sentence is written in there and it called it as a preposition.
My teacher called it as a preposition and he also said, it can be idiomatic adverb. Then also gave me a sentence: The hotel is anything but satisfactory —from OLAD. I am not sure what actually he shared but I am eagerly waiting for your clarification.
Kindly, analyze the sentence structurally and remove this confusion with your remarks. Thanks in advance!