package main

import "fmt"

func CallByCopy(n int, b [5]int, c []int){
	n = 3000
	b[0] = 1000
	c[3] = 500
}

func main(){
	var array [5]int = [5]int{1,2,3,4,5}
	var c []int
	c = array[:]
	CallByCopy(100, array, c) 
	fmt.Println(array) // [1,2,3,500,5]
	fmt.Println(c) // [1,2,3,500,5]
}