Sha256: 1eda2885fd139d0bbed201760c152c90f5a314da913c5f5ecba4f6845d71ede4
Contents?: true
Size: 436 Bytes
Versions: 33
Compression:
Stored size: 436 Bytes
Contents
#import "AllergiesExample.h" @interface Allergies () @property (nonatomic, assign) int score; @end @implementation Allergies - (instancetype)initWithScore:(int)score { self = [super init]; if (self) { self.score = score; } return self; } - (BOOL)hasAllergy:(Allergen)allergen { if ((allergen & self.score) == allergen) { return true; } else { return false; } } @end
Version data entries
33 entries across 33 versions & 1 rubygems