Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save jjuliano/fe44cc3e4b0bca1e61f1abfe7a2ecd74 to your computer and use it in GitHub Desktop.
Save jjuliano/fe44cc3e4b0bca1e61f1abfe7a2ecd74 to your computer and use it in GitHub Desktop.
package main
import (
"github.com/google/uuid"
"fmt"
)
func main() {
var array []interface{}
array = []interface{}{"apple", 1, uuid.New()}
fmt.Println(array[0]) // apple
fmt.Println(array[1]) // 1
fmt.Println(array[2]) // XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment