assume there is a function like $f:A→B$ which is injective, why it means $\left|A\right|\le\left|B\right|$ or in another way why a function like $g:B→A$ stands for $\left|B\right|\le\left|A\right|$
my problem has been clearly explained here: assume a set like $A=[1,2,3,4]$ and $B=[1,2,3]$ and for $f:A→B$ we have $f=[(1,1)(2,2),(3,3)]$ and $f$ is still injective but $\left|A\right|=4$ and $\left|B\right|=3$ and in this case $\left|B\right|\le\left|A\right|$...
In your example $f$ is not a vell defined function since $4$ is out of it domain, so it can not be injective since is not a function.
But you can make it a function as soon as you say $f(4)$ is something in $\{1,2,3\}$. But then it is not injective.
In general if $|B|<|A|$ then two different $a,b$ in $A$ must have the same picture, so $f$ can not be injective.