public Locale pop() throws Exception {
        Locale retVal = null;
        // Check for stack underflow.
        if (topPtr < CAPACITY) {
            retVal = arr[topPtr];
            topPtr = topPtr + 1;
        } else {
            Exception underflow = new Exception("Stack Underflow");
            throw underflow;
        }
        return retVal;
    }