public String last() {
        if (elements.isEmpty()) return "";
        return elements.get(elements.size() - 1);
    }
Returns the last element in this, or the empty string if this path is empty
vespajlib/src/main/java/com/yahoo/path/Path.java