Hello there, I've just signed up to this forum after getting confused with the 2nd quiz in the tutorial. First up I just want to say how pleased I am to have found this website, it is really great!
Years ago I learned how to program quite well in BASIC, i made quite a few games as personal projects. Yesterday I began learning C++ thanks to this site, after downloading Dev-C++
So far everything is going fine, last night I spent ages on the first tutorial, making notes as I went along, trying the examples, altering them, and basically spending as much time on it as I could. Today I woke up and tried the 2nd, with if statements. This was all a lot more familiar to me from BASIC (apart from using && instead of and etc).
The only thing that has confused me is a part of the quiz.
3. Evaluate !(1 && !(0 || 1)).
Apparently the answer is A, True, but I would appreciate it if someone please explained to me how this is possible?
When I see that, I read it as:
NOT(1 AND NOT(0 or 1))
If something isnt (0 or 1, plus 1), then how can it return true?
Thanks for any help, I'm just a bit baffled at this, everything else is going swimmingly so far. Cheers!