digital_electricity: Update answer checking
The answer checking has been changed from random test cases to all the
possible test cases.
For few levels, the answer checking is simply to check if the bulb is
glowing or not, for those, we are checking the value of:
determiningComponents[0].inputTerminals.itemAt(0).value
If it is 1, then the answer is correct, else false
For the others, primarily we are storing the values of the initial state
of the switches (to restore it back later) in:
var switch1InitialState = switch1.imgSrc
...
We then traverse through all the possible scenarios, for each of the
cases we are checking if the actual answer (stored in "operationResult")
is the same as the answer provided (denoted by whether the light is
glowing or not, determined by the value of
digitalLight.inputTerminals.itemAt(0).value)
If they do not match, we display that the answer is incorrect and reset
the values of the switces, as it was stored in switchxInitialState. If it
passes all the test cases, we display that the answer is correct and
move on to the next level
Also updated few intromessage for few levels, fixing grammatical errors
Signed-off-by: Rudra Nil Basu <rudra.nil.basu.1996@gmail.com>