Welcome to collectivesolver - Programming & Software Q&A with code examples. A website with trusted programming answers. All programs are tested and work.

Contact: aviboots(AT)netvision.net.il

Instant Grammar Checker - Correct all grammar errors and enhance your writing

Semrush - keyword research tool

Linux Foundation Training and Certification

Teach Your Child To Read

Disclosure: My content contains affiliate links.

32,310 questions

42,485 answers

573 users

How to add two numbers in Objective-C

1 Answer

0 votes
#import <Foundation/Foundation.h>

int main (int argc, const char *argv[]) {
    NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];

    int x = 10;
    int y = 25;
    NSLog(@"x + y = %i", (x+y));

    [pool drain];
    return 0;
}



/*
run:

x + y = 35

*/

 



Learn & Practice Python
with the most comprehensive set of 13 hands-on online Python courses
Start now


answered Dec 11, 2022 by avibootz
edited Dec 11, 2022 by avibootz

Related questions

...