When declaring a controller I usually see these:
University.controller('ClassroomController', function($scope){
//do stuff
});
What's the difference of it compared to:
var classroomController = function ($scope){
//do stuff
}
University.controller('ClassroomController',['$scope',classroomController])
The tutorials doesn't seem to say whats the advantage of the second type of declaration.