end() is a better last element selector than counting the array elements
Run jquery in noConflict mood - incase you have other libraries that uses $