title: AngularJS controller syntax - difference between array and function version
body: <p>I am new to AngularJS. What is difference between a controller declared with an array parameter, listing the dependencies both as strings and as JavaScript names,</p>
  
  <pre><code>app.controller("firstController", ['$scope', '$modal', '$log', 'HttpService', 'FisrtSharedService', 'SecondSharedService', function($scope, $modal, $log, HttpService, FisrtSharedService, SecondSharedService) {
  
  }]);
  </code></pre>
  
  <p>...and this form, listing just the JavaScript names?</p>
  
  <pre><code>app.controller("firstController", function($scope, $modal, $log, HttpService, FisrtSharedService, SecondSharedService){
  
  });
  </code></pre>
  
  <p>Why the weird syntax in the first version?</p>