package main import ( "fmt" "github.com/spf13/pflag" ) func main() { var verbose bool fs := pflag.NewFlagSet("example", pflag.ExitOnError) fs.BoolVar(&verbose, "verbose", false, "print verbose output") fs.Parse([]string{"--verbose"}) fmt.Println("Verbose set to:", verbose) }In this example, we create a new FlagSet and a boolean flag named "verbose" with default value "false" and usage message "print verbose output". We then parse the command-line arguments and set the value of the "verbose" flag to true. Finally, we print the value of the "verbose" flag. Overall, this package provides a convenient and easy-to-use way of parsing command-line arguments in Go programs.