Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

iOS Build a Blog Reader iPhone App Exploring the Master-Detail Template Modifying the Master-Detail Template

Can't get through this challenge...

Excuse my ignorance if so...but I believe the answer is

NSString *bookTitle = [self.booksArray objectAtIndex:2];

I wrote it in the editor, but apparently I have something wrong..Checking back the code, that's the same line we have in the project, so..I don't know where am i wrong. Can you please help me?

2 Answers

Thomas Nilsen
Thomas Nilsen
14,957 Points

First of all you don't need 'self' since both variables are created locally. The answer should look something like this:

NSString *bookTitle = booksArray[2];

The way you wrote it, apart from 'self' is correct, so it depends on the compiler :)

Thank you very much, taking out the 'self' did the trick..

Sorry for the dumb question :S ..just starting on iOS Development :P