Functions
8 min · Swift
Package code under a name so you can reuse it.
Swift · Functions0/5 cleared
Enemy 1 of 5
Define a function with func. Each parameter has a type, and the return type follows -> . The underscore lets you call it without a label.
Use return to hand a value back.
You
Syntax Skeleton
Loading editor...
Ln 1, Col 1Spaces: 4
Sign up to fightTarget output: 10