var $ = function(id){ return getElementById . document (id); } code example
Example: what does document.getelementbyid return
function changeColor(newColor) {
var elem = document.getElementById('para');
elem.style.color = newColor;
}
function changeColor(newColor) {
var elem = document.getElementById('para');
elem.style.color = newColor;
}