Go Concepts - Functions: Difference between revisions
Jump to navigation
Jump to search
(→Syntax) |
|||
Line 8: | Line 8: | ||
<pre> | <pre> | ||
func <name>(< | func <name>(<parameter-identifier1> <type1>, <parameter-identifier2> <type2>, ...) (<return-type1>, <return-type2>, ...) { | ||
statement1 | statement1 |
Revision as of 21:48, 17 March 2016
Internal
Overview
Syntax
func <name>(<parameter-identifier1> <type1>, <parameter-identifier2> <type2>, ...) (<return-type1>, <return-type2>, ...) { statement1 statemen2 ... return <return-value1>, <return-value2> }
Built-in Functions
Closures
Anonymous function that capture local variables.
More about closures is available here.