trying_out_go/cmd/playground/double.go

14 lines
149 B
Go

package main
import "fmt"
func makeDouble(number *int) {
*number *= 2
}
func double() {
amount := 6
makeDouble(&amount)
fmt.Println(amount)
}