def search(state, path):
    """Get value in `state` at the specified path, returning {} if the key is absent"""
    if path.strip("/") == '':
        return state
    for p in path.strip("/").split("/"):
        if p not in state:
            return {}
        state = state[p]
    return state