You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fn on_click { |btn, callback|
# run the callback when the button is clicked
}on_click(my_btn){puts("clicked!")}fn map { |array, f|
# for each element in array, apply f
}map([1,2,3]){ |element| element *2}
The text was updated successfully, but these errors were encountered:
func loadPicture(from server:Server, completion:(Picture)->Void, onFailure:()->Void){
if let picture =download("photo.jpg", from: server){completion(picture)}else{onFailure()}}loadPicture(from: someServer){ picture in
someView.currentPicture = picture
} onFailure:{print("Couldn't download the next picture.")}
The text was updated successfully, but these errors were encountered: