mirror of
https://github.com/SourceFellows/gobuch.git
synced 2025-08-03 05:02:16 +02:00
Verlinkungen zu Beispielen eingefügt.
This commit is contained in:
12
golang-language-samples/varadic-parameter/main.go
Normal file
12
golang-language-samples/varadic-parameter/main.go
Normal file
@ -0,0 +1,12 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func something(text string, i ...int) int {
|
||||
fmt.Println(i[0])
|
||||
return i[1]
|
||||
}
|
||||
|
||||
func main() {
|
||||
fmt.Println(something("hello", 1, 2))
|
||||
}
|
Reference in New Issue
Block a user