Exercise: Find an example of mapping which is open but not closed, which is closed but not open.
I am thinking of trivial examples with $X=\{1,2,3\}$ however I have no idea on how to build a function that preserves the open interval but no the closed ones. Since this is my first exercise of this kind.
Question:
Can someone give me a hint?
Thanks in advance!