see this link:
http://www.goiit.com/posts/list/integral-calculus-how-to-check-1-1-onto-into-many-one-function-991342.htm
Give different ways of finding whether a function is onto or not.
see this link:
http://www.goiit.com/posts/list/integral-calculus-how-to-check-1-1-onto-into-many-one-function-991342.htm