Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.

1. Truth Table Question

Hi All,

Is

NOT (NOT A AND B) as shown below

A B
T T
F F

and does

A OR NOT B mean the same thing?

A B
T T
F F

This was part of a question in an assignment that I had to submit by yesterday, which I did, but unfortunately I still don't think I have the gist of this!

• Not quite sure what this has to do with Javascript, and my formal logic is a bit rusty, but basically, it depends what you mean by 'means the same as'. As I remember, there are two ways of saying this with logic, 'entailment' and something else that I forget the term for, |= and |- if you're writing them I believe.
Dpending on which you want to use, then the answer is 'yes' or 'no', but I forget which way round. If you have a textbook for this, then it will probably tell you, as I think this was an example of the difference on our course.

I could, of course, be getting confed, and this might all be wrong.

• Hi GJay,

Thanks for your reply to my query. The truth table was part of an assignment that I have just had to submit in my Javascript course, so although I am having trouble getting my head around it it must have something to do with Javascript somewhere along the line. The problem I am having is with the double negative, ie; does NOT (NOT A AND B) mean it is A and B, ie; A is True and B is True? The way I have written the table is exactly how it was posed in the test paper.

Thanks for trying to help though.

Kindest regards,

Jenny

• Code:
```a=array(true,false);
b=array(true,false);
i=0;
while(i<a.length) {
j=0;
while(j<b.length) {
j++;
}
i++;
}```
Will show whether the statement:
!(!a&&!b))=a||!b
is always true (i.e. each side is the same)

• Hi GJay,

Kindest regards,

Jenny

• Just use DeMoivre's theorem:

!(!A & B) = !!A | !B = A | !B

Thus, NOT (NOT a AND b) is equivalent to: a OR NOT b

•

Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•