Show that for finite K-vector spaces U, V, W with $f:U \rightarrow V$ and $g:V \rightarrow W$ linear it follows that:
$$\operatorname{rank}(g \circ f) \le \min(\operatorname{rank}(f), \operatorname{rank}(g))$$
Hm ok so we know that:
$$\operatorname{rank}(f)=\dim_K(\operatorname{im}(f))$$
$$\operatorname{rank}(g)=\dim_K(\operatorname{im}(g))$$
$$\operatorname{rank}(g \circ f)=\dim_K(\operatorname{im}(g \circ f))$$
I don't really know how to proceed here. Can somebody give me a hint?
Here's a hint: if $f : V \to W$ is a linear transformation with a finite rank $r$, then given any list of vectors $v_1, \ldots, v_n \in V$, the images $f(v_1), \ldots, f(v_n)$ can only contain at most $r$ linearly independent vectors. It doesn't matter if $v_1, \ldots, v_n$ are linearly independent or not, this still holds true.
Prove this, and examine what happens to a basis of $U$ when mapped first under $f$, then under $g$.