See http://www.artofsolving.com/node/12
See http://www.artofsolving.com/node/12