package main import ( "fmt" "reflect" ) func main() { // create a reflect value of a function add := reflect.ValueOf(add) // create reflect values for the function arguments arg1 := reflect.ValueOf(5) arg2 := reflect.ValueOf(10) // create an array of reflect values to hold the function arguments args := []reflect.Value{arg1, arg2} // invoke the function using the reflect values result := add.Call(args) // get the result as an integer sum := result[0].Int() fmt.Println(sum) // Output: 15 } func add(a, b int) int { return a + b }In this example, we create a reflect value of the `add` function and call it using the `Call` method. We create the reflect values for the function arguments and add them to an array, which is then passed as an argument to the `Call` method. Finally, we extract the result from the returned array and convert it to an integer. This example demonstrates how the reflect package can be used to dynamically invoke a function at runtime. Package library: `reflect`