Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
Also - someone mentioned reading a lot of nested brackets. Nested brackets are a bad code smell - the logic should be reworked, likely so that some of it is in entirely seperate functions or methods.

Or even just variables.
Code:
NSArray *theArray = [aDictionary objectForKey:@"dictKey"];
int arrayCount = [the Array count];
...
 
Thanks for all the advice guys.

I don't know much about debugging. However the course I am doing will get to there. Cannot wait as I am sure my life as a programmer will be much easier. And not just putting NSLogs all over the place and staring at code - there must be a better way to do it.

I'm going t pick up a few books on OOP design and a book about a project life cycle - so I know how to tackle new developments - where to start etc.
 
Thanks for all the advice guys.

I don't know much about debugging. However the course I am doing will get to there. Cannot wait as I am sure my life as a programmer will be much easier. And not just putting NSLogs all over the place and staring at code - there must be a better way to do it.

Why wait?

There's nothing wrong with jumping ahead and learning all about using Unit Tests. I believe if you Google a bit you can find Apple's official documentation on how to use unit tests in Xcode. Ray Wenderlich also has a tutorial on how to use alternative unit testing suites in Xcode (I haven't found the limits of Apple's built in suites yet, though.)
 
Why wait?

There's nothing wrong with jumping ahead and learning all about using Unit Tests. I believe if you Google a bit you can find Apple's official documentation on how to use unit tests in Xcode. Ray Wenderlich also has a tutorial on how to use alternative unit testing suites in Xcode (I haven't found the limits of Apple's built in suites yet, though.)

Do you really find unit tests useful for testing GUI applications?

Sure, if you have an app that has a database component and a server component, etc, you can unit test those, but the hardest thing to test in my experience is the user interaction, and the inherently non-linear nature of event-driven applications.
 
Do you really find unit tests useful for testing GUI applications?

Sure, if you have an app that has a database component and a server component, etc, you can unit test those, but the hardest thing to test in my experience is the user interaction, and the inherently non-linear nature of event-driven applications.

Xcode facilitates the creation of GUI unit tests, and though I haven't made a GUI intensive app using them, I do see the value.

Mostly I've used unit tests for methods that are supposed to manipulate strings and whatnot, so I can test my regex and databases.

But if you have a GUI heavy app, then I definitely see the value still. Suppose you've found that navigating your views in a certain order causes a bug to occur. While you're trying to fix it, why manually navigate your app each time you make a change in the code to see if you've squashed the bug yet or not? Just write a test that'll simulate those user actions and check if the bug is present. Further, when you're making other tweaks and that bug shows up again, if you're running your user tests, it'll let you know the moment you've reintroduced that bug. Apple has some documentation on how to write unit tests that test your UI... I don't have the link on hand but you should look for it.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.