iOS Closures in Swift First Class Functions Higher Order Functions

Roop P
Roop P
Pro Student 6,937 Points

string extensions

Code Looks right but wont pass.

// Enter your code below
extension String {
  func transform(_ value: (String) -> String) -> String {
  return value(self)

1 Answer

Jason Anders
Jason Anders
Treehouse Moderator 145,084 Points

Hey there,

You're just missing the closing curly brace for the extension. Other that that... looks good! :thumbsup:

Keep Coding! :) :dizzy: