A tree structure is shown below where each node has a reference to its parent, a reference to its first child  and a reference to its right sibling.

class Node {
    Object item;
    Node parent, firstChild, rightSib;

a)Write a method that returns the next node at the same level on the right.  If you use any helper methods, you must provide their implemetation as well.
b) What is the complexity of your method?  Explain how you computed it.
The signature of the method is:

Node GetNextLevelSibling(Node p);


GetNextLevelSibling(f) -> g
GetNextLevelSibling(k) -> l
GetNextLevelSibling(h) -> i
GetNextLevelSibling(d) -> null
Traditional Diagram of a Tree

Actual Diagram of Tree for Question #1 showing all references