Snap! thinks the square root of -1 is not equal to the square root of -1

blockJS-1.0 script pic (1)
blockJS-1.0 script pic (2)
blockJS-1.0 script pic (3)
I'm just so confused right now. If NaN = NaN and sqrt(-1) = NaN, why doesn't sqrt(-1) = sqrt(-1)?

It because the this NaN untitled script pic (27) is different from this Nan untitled script pic (28) is different from this NaN untitled script pic (29). The first two are not actually text: untitled script pic (34), untitled script pic (33) , while the last one is: untitled script pic (35). In the first cases, NaN stands for "Not a Number", meaning that the result is undefined and not even a number. However, they are not considered equal by snap as they could represent different "not a numbers".

Not just Snap!, which is written in JavaScript, which uses the IEEE floating-point standard*, which specifies certain criteria of bits to represent NaN and NaN is never equal to any other value (even itself or other NaN values).
*That's the official website, but other sources (e.g. GeeksforGeeks) probably explain it better.