$(document).ready(function(){
    /*var box = document.getElementsByTagName('a-box');

    var changeColor = function() {
        this.setAttribute('color', 'green');
    };
    var returnColor = function() {
        this.setAttribute('color', '#4CC3D9');  
    };

    for (var i = 0; i < box.length; i++) {
        box[i].addEventListener('mouseenter', changeColor, false);
        box[i].addEventListener('mouseleave', returnColor, false);
    }*/


    $( "a-box" ).hover(
        function(){
            $(this).setAttribute('color', 'green');
        },
        function(){
            this.setAttribute('color', '#4CC3D9');            
        }
    );
});
$(document).ready(function(){
    var box = document.getElementsByTagName('a-box');

    var changeColor = function() {
        this.setAttribute('color', 'green');
    };
    var returnColor = function() {
        this.setAttribute('color', '#4CC3D9');  
    };

    for (var i = 0; i < box.length; i++) {
        box[i].addEventListener('mouseenter', changeColor, false);
        box[i].addEventListener('mouseleave', returnColor, false);
    }
});
--- 
+++ 
@@ -1,5 +1,5 @@
 $(document).ready(function(){
-    /*var box = document.getElementsByTagName('a-box');
+    var box = document.getElementsByTagName('a-box');
 
     var changeColor = function() {
         this.setAttribute('color', 'green');
@@ -11,15 +11,5 @@
     for (var i = 0; i < box.length; i++) {
         box[i].addEventListener('mouseenter', changeColor, false);
         box[i].addEventListener('mouseleave', returnColor, false);
-    }*/
-
-
-    $( "a-box" ).hover(
-        function(){
-            $(this).setAttribute('color', 'green');
-        },
-        function(){
-            this.setAttribute('color', '#4CC3D9');            
-        }
-    );
+    }
 });
Use hover method to increase code readability
