Are all finite languages context-free? As far as I know, finite languages have a finite number of strings or words, while context-free languages are generated by context-free grammars. I don't know which aspect should I know that they are correlated with. All I know is that finite languages are regular, and regular languages are context-free. How should I know this?
The language consisting of the words $w_1,w_2,\ldots,w_n$ is generated by the context-free grammar
$$
S \to w_1 \mid w_2 \mid \cdots \mid w_n.
$$