= is assignment
== is comparison
comparing a boolean against true or false is superfluous.
I guess that you've received «error: `foo' was not declared in this scope» messages and so prefixed every use of your variable with its type. That's not how it works.
read about scope http://www.cplusplus.com/doc/tutorial/namespaces/
variables exist in the block they are declared and names are meaningless.
1 2 3 4 5 6 7 8 9 10 11 12 13
bool n = sensors.getTemmpFByIndex(0) < 212;
if(n)
digitalWrite(10, HIGH);
else
digitalWrite(10, LOW);
bool m = sensorValue<=0 and sensorValue<=25;
bool p = m and n;
while (p)
{
digitalWrite(10, HIGH);
//¿does `p' change here?
}