What does this construct mean?
var digits = [1, 2, 3];
(function fetchData(name){
//body
})(digits.shift());
which construct?
I can explain what's happening, if that will help:
(in the order of execution)
Declare a function and call it.
Click on this http://jsfiddle.net/TC8K6/ you will see a alert of the parameter passed to the function.