Created
March 19, 2015 01:03
-
-
Save lettergram/a8f2b473dab0438f3862 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type dataone struct { | |
Value int | |
} | |
type datatwo struct { | |
Value int | |
Name string | |
} | |
func example() { | |
g := Graph{} | |
g.Node = make(map[string]Node) | |
AddNode(&g, Node{"node1", dataone{1}, nil}, "node1") | |
AddNode(&g, Node{"node2", datatwo{1, "bob"}, nil}, "node2") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment