Difference between objectAtIndex and [0]
<p>What is the difference between using the following: </p>

<pre><code>NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);

    NSString *dir = [paths objectAtIndex:0]; 

    NSString *dir2 = paths[0]; // this throws incompatible type exception
</code></pre>
