A stack is a LIFO data structure, so when you iterate over it (e.g., with String.Join), the elements are accessed in reverse order of insertion.
so If you want the elements in the order they were added you need to reverse the stack before joining. Like..
String.Join("/", stack.Reverse());