Formula Questions- it doesn't calculate b^n1 in the Answer

Formula Questions- it doesn't calculate b^n1 in the Answer

de Ahmad Amer -
Número de respuestas: 1

When I try to solve the problem,

it gives me an incorrect because it doesn't calculate (b^n1) as it is defined in my variables

(it gets the top answer box right as well as the right answer box but somehow it fails to calculate b^n1 for the bottom answer box).

is there an explanation to this problem? How do I deal with it?

Thanks.



Promedio de valoraciones: -
En respuesta a Ahmad Amer

Re: Formula Questions- it doesn't calculate b^n1 in the Answer

de Dominique Bauer -
Imagen de Documentation writers Imagen de Particularly helpful Moodlers Imagen de Plugin developers
In the answer, b^n1 represents the bitwise operator XOR. Therefore, 3^2 is equal to 1, not 9.

Use the appropriate syntax, that is, the exponentiation operator ** (recommended) or the power function pow(). So you must write:

Answer   [b**n1,1,n1]

or

Answer   [pow(b,n1),1,n1]