Added Traversal Function and updated variable names