One of the definitions of compact operators is the following.
Definition: Let X and Y be two Banach spaces. An operator $T : X \rightarrow Y$ is compact if for every bounded set $ \subset X$ and every sequence $(x_i) \subset M$, the sequence $(Tx_i)$ contains a convergent subsequence.
Edit:
Another definition for compact operator is: $T$ maps bounded sets $M$ to relatively compact sets, $TM$, in the codomain.
Notice that this is weaker than mapping bounded sets to compact sets since we do not have the requirement that $TM$ is compact because it is possible that $TM$ is not closed.
Problem: I am trying to find a bounded set whose image under a compact operator is not closed.
Thanks in advance.
Let $f : (c_{0}, \|\cdot\|_\infty) \to \Bbb{C}$ be the linear functional $$f(x)=\sum_{n=1}^\infty \frac{x_n}{2^n}, \qquad \text{ for all }x = (x_n)_n \in c_0.$$ Then $f$ is clearly compact since it has finite rank. However, the image of the open unit ball in $c_0$ is the open unit ball in $\Bbb{C}$ which is not a closed set in $\Bbb{C}$.