declare 'pos' variable