I would recommend starting by learning the basics of programming before messing with the intricacies of iPhone programming. While it is certainly possible to use Objective-C as a learning language, the resources out there for learning it mostly assume knowledge of another language, and iPhone development in particular has a variety of quirks inherent to a (relatively) new SDK and working on an external device or in a simulator.
How to think like a computer scientist: Learning With Python
The most relevant sections come later (e.g., Chapter 13), but it covers most of the basics. Python is a good language to start from for learning those basics.
If you prefer a C-derived language, there's always
Java or
C++, the last of which is closest to Objective-C.
If you really insist on getting started immediately with Objective-C:
Code:
[[myClassFile alloc] init] myFunction];
alloc allocates the memory.
init acts as a
constructor.
myFunction is your function and can then be called after the object has been created.