You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: variadic-functions.go
    path of file: ./repos/gobyexample/examples/variadic-functions
    
    the code of the file until where you have to start completion: // [_可变参数函数_](https://zh.wikipedia.org/wiki/%E5%8F%AF%E8%AE%8A%E5%8F%83%E6%95%B8%E5%87%BD%E6%95%B8)。
//
    
func main() {

	// 变参函数使用常规的调用方式，传入独立的参数。
	sum(1, 2)
	sum(1, 2, 3)

	// 如果你有一个含有多个值的 slice，想把它们作为参数使用，
	// 你需要这样调用 `func(slice...)`。
	nums := []int{1, 2, 3, 4}
	sum(nums...)
}