diff --git a/README.md b/README.md index 77c8100..b80d2ec 100644 --- a/README.md +++ b/README.md @@ -23,11 +23,12 @@ The library consits of an interface `Node` and an implementation `NodeItem`. ## Add a child node - root.createChild("child"); + Node child = root.createChild("child"); Which is shorthand for: - root.addChild(new NodeItem<>("child")); + Node child = new NodeItem<>("child"); + root.addChild(child); The tree now looks like: