How is sex (gender) determined in mammals?

I was thinking that if the male gave over an X chromosome that the baby would for sure be a male because males have XY and if the male gave over an X then baby would for sure be a female because all females ar XY.

Am I right? And could you elaborate a bit please.

Proofread your questions more carefully before posting them. What you have does not make sense.

Genetically, if a male gives an X, the child will be female (XX). If the male gives a Y, the child will be male (XY). Normally, the mother only gives an X chromosome.

I hope this helps a little more. Thanks for asking.