Which
/wɪt͡ʃ/
pronoun
(interrogative) What one or ones (of those mentioned or implied).
“By now, you must surely know which is which.”
The/Any ones that; whichever.
“Please take which you please.”
(relative) Introduces a relative clause giving further information about something previously mentioned.
“He had to leave, which was very difficult.”