google chrome path in mac

package main

import (
    "fmt"
    "os/exec"
    "runtime"
)

func main() {
    var chromePath string

    switch runtime.GOOS {
    case "darwin":
        out, err := exec.Command("mdfind", "kMDItemCFBundleIdentifier == 'com.google.Chrome'").Output()
        if err != nil {
            fmt.Println("Error:", err)
            return
        }
        chromePath = string(out)
    default:
        fmt.Println("Unsupported OS")
        return
    }

    fmt.Println("Google Chrome Path:", chromePath)
}