Thank you for agreeing to take part in this experiment. Do NOT write your name on the paper. It is intended that the results be anonymous. This experiment is part of a study looking at developer's knowledge of operator precedence. Background information about you:

    a)  How many lines of code would you estimate you have written in different languages over your career:

        i)  50,000

        ii) 75,000

        iii)
            100,000

        iv) 150,000

        v)  200,000

        vi) 275,000

        vii)
            350,000

    b)  How many lines of code would you estimate you have read in different languages over your career:

        i)  50,000

        ii) 75,000

        iii)
            100,000

        iv) 150,000

        v)  200,000

        vi) 300,000

        vii)
            500,000

    c)  How many years have you been writing software professionally?
What you have to do This is not a race and there are no prizes for providing answers to all questions. Please work at a rate you might go at while reading source code. The task consists of remembering the value of three different variables and recalling these values later. The variables and their corresponding values appear on one side of the sheet of paper and your response needs to be given on the other side of the same sheet of paper.

    1)  Read the variables and the values assigned to them as you might when carefully reading lines of code in a function definition.

    2)  Turn the sheet of paper over. Please do NOT look at the assignment statements you have just read again, i.e., once a page has been turned it stays turned.

    3)  Look at each expression in turn and work out which operator will be evaluated first (ie, has the highest precedence). Use parenthesis to bracket the operator and its two associated operands. These parenthesis are redundant in that they do not change the behavior of the expression.

    4)  You are now asked to recall the value of the variables read on the previous page. There is an additional variable listed that did not appear in the original list.

        a)  if you remember the value of a variable write the value down next to the corresponding variable,

        b)  if you feel that, in a real life code comprehension situation, you would reread the original assignment, tick the "would refer back" column of the corresponding variable,

        c)  if you don't recall having seen the variable in the list appearing on the previous page, tick the "not seen" column of the corresponding variable.
If you do complete all the questions do NOT go back and correct any of your previous answers.

 p = 13;
 q = 72;
 r = 29;

x + y * z
x / y == z
x != y - z

remember would refer back not seen

 q =     ____    __    __

 p =     ____    __    __

 z =     ____    __    __

 r =     ____    __    __