Objective-C
Posted: Sun Jan 25, 2004 1:20 pm
Would anybody be able to explain to me what Objective-C is/what it's used for?
Objective-C, as the name implies, is an OOP variant of C; it was developed around the same time as C++, and the two languages were rivals throughout the 1980s; Objective-C was the major language on the Next workstation.. While C++ eventually won out, Objective-C continued to be used in certain projects, such as the GNUStep window manager and the Cocoa development kit. The gcc compiler system supports Objective-C as a source language.chris wrote: Would anybody be able to explain to me what Objective-C is/what it's used for?
Code: Select all
/* W.J. Antel Jr. 12/12/96
** Compile with gnu's gcc: gcc hello.m -lobjc
*/
#include
@interface Control:Object
{
}
- world;
void main();
@end
@implementation Control
- world
{
printf("Hello, World!\n");
}
void main()
{
id hello;
hello=[Control new];
for(;;)
[hello world];
}
@end