The last line of the code above, passes the HTML DOM document object to jQuery: $(document).
When you pass DOM objects to jQuery, jQuery returns new jQuery objects wrapped around the HTML DOM objects.
The jQuery function returns a new jQuery object, where ready() is a method.
Since functions are variables in jQuery, myFunction can be passed as a variable to the jQuery ready() method.