Every stack has a size that determines how many nodes it can accommodate. Attempting to push a node in a full stack will result in a stack overflow. The program may crash due to a stack overflow.
A stack is illustrated in the given image.
stackA.push(xg) will result in a stack overflow since the stack is already full.