isn't this function deterministic as well?