返回值

如果要從方法返回值,請將要返回的型別放在第一組括號中。

- (NSString)returnHello {
  return @"Hello World";
}

你要返回的值位於 return 關鍵字之後;