yearAsObject = [NSNumber numberWithInteger:self.yearReleased];
return [NSString stringWithFormat:@"%@ by %@. Released in %@.",
self.title, self.studio, yearAsObject];
can we just use self.yearReleased to return the int ?
return [NSString stringWithFormat:@"%@ by %@. Released in %@.",
self.title, self.studio, self.yearReleased];
by CY — Jul 31
I am new to Obj - C, I don't understand
this line
yearAsObject = [NSNumber numberWithInteger:self.yearReleased]; return [NSString stringWithFormat:@"%@ by %@. Released in %@.", self.title, self.studio, yearAsObject];
can we just use self.yearReleased to return the int ?
return [NSString stringWithFormat:@"%@ by %@. Released in %@.", self.title, self.studio, self.yearReleased];
thanks in advance