term_variables(Term, List) is true if and only if List is a list made up by the variables of Term, in order of appearance and with no repetition.