Placing the script in the head of the page was common back in the days of embedding event handlers in the HTML as this ensured that the functions that those handlers called were already loaded by the time that the handler was added to the page. This avoided the problem of a handler trying to call a function that wasn't loaded yet. So for the same reason Netscape scripts needed to be added in the head, modern scripts need to be added to the bottom of the body.
In addition with the script in the head you need extra code to delay trying to add the event listeners until after the HTML finishes loading and not all browsers provide a way to test if the HTML is fully loaded without having to wait for all the other files to finish loading as well. Simply by moving the script to the bottom of the body you do away with the need for this extra code, speed up the rendering of the page, and get the script to run sooner than it otherwise might.
Google calls any script a blocking script if it is attached in the page at a point where it would slow the rendering of the part of the HTML above the fold. Such pages receive a penalty for this because they are slower loading than pages that don't contain blocking scripts. So for SEO purposes there is also a benefit to moving the script to the bottom of the body.
This article written by Stephen Chapman, Felgall Pty Ltd.