You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
714 B
43 lines
714 B
10 years ago
|
/*
|
||
|
* Copyright (c) 2014 - Facebook.
|
||
|
* All rights reserved.
|
||
|
*/
|
||
|
|
||
|
#import "Boxing.h"
|
||
|
|
||
|
@implementation Boxing
|
||
|
|
||
|
- (NSNumber*)getIntExp {
|
||
|
int x = 4;
|
||
|
int y = 5;
|
||
|
NSNumber *n = [NSNumber numberWithInt: x+y];
|
||
|
return @(x+y);
|
||
|
}
|
||
|
|
||
|
- (NSNumber*)getInt {
|
||
|
NSNumber *n = [NSNumber numberWithInt: 5];
|
||
|
return @5;
|
||
|
}
|
||
|
|
||
|
- (NSNumber*)getFloat {
|
||
|
NSNumber *n = [NSNumber numberWithFloat: 1.5f];
|
||
|
return @1.5f;
|
||
|
}
|
||
|
|
||
|
- (NSNumber*)getDouble {
|
||
|
NSNumber *n = [NSNumber numberWithDouble: 1.5];
|
||
|
return @1.5;
|
||
|
}
|
||
|
|
||
|
- (NSNumber*)getBool {
|
||
|
NSNumber *n = [NSNumber numberWithBool: YES];
|
||
|
return @YES;
|
||
|
}
|
||
|
|
||
|
- (NSString*)getS{
|
||
|
NSString *s = @(strdup("hello world")) ;
|
||
|
return [NSString stringWithUTF8String: "hello world"];;
|
||
|
}
|
||
|
|
||
|
@end
|