Trying to figure out how to explain xor. Manual does a poor job of even mentioning the command. Weregoose explained it to me, and now I *think* I have an understanding of it. We shall see...
Code:
a = 1
b = 2
if (a == 1 xor b==2) //this will return false)
if (a == 1 xor b==3) //this will return true
I hope that helps.

elfprince13
 OVER NINE THOUSAND! (Posts: 11880)
 15 Jan 2007 02:03:03 pm
 Last edited by elfprince13 on 17 Jan 2007 02:18:10 pm; edited 2 times in total
truth tables ftw
==========
p0101
==========
q0011
==========
p xor q0110
==========
==========
p0101
==========
q0011
==========
p xor q0110
==========
I think your truth table is wrong... if both variables are "true" than xor returns 0, if only one is "true", than it returns 1. That is what the table shows in the manual anyways...
http://tifreakware.net/tutorials/83p/b/tifw/les4.htm
I am hoping that someone might have some time to look it over, see what they think. I am trying to make sure I have covered all the angles, at least from what has been shown so far. I am only holding back info on things that the person has not yet learned about, that would tie in with the commands.
I am hoping that someone might have some time to look it over, see what they think. I am trying to make sure I have covered all the angles, at least from what has been shown so far. I am only holding back info on things that the person has not yet learned about, that would tie in with the commands.
Look good to me; other than the disclaimer you already mentioned on the missing function extensions, I see nothing omitted.
elfprince13 wrote:
whoops, I posted the OR truth table *sheepish* typoed.
No you didn't, that's the NOR truth table. Methinks you need to take a digital logic course.
lol, its all good.
I am just glad that I got the explanation correct in the tutorial...
Kerm, could you point out the "disclaimers" plx?
I am just glad that I got the explanation correct in the tutorial...
Kerm, could you point out the "disclaimers" plx?
tifreak8x wrote:
...I am only holding back info on things that the person has not yet learned about, that would tie in with the commands.
oh, you had me confused there... I thought you meant it was posted twice in the lesson... >.<
Twould be nice if I could find the & ; codes for >= and <=... Anyone happen to know those?
Twould be nice if I could find the & ; codes for >= and <=... Anyone happen to know those?
KermMartian wrote:
elfprince13 wrote:
whoops, I posted the OR truth table *sheepish* typoed.
No you didn't, that's the NOR truth table. Methinks you need to take a digital logic course. no, I think edited it, and didn't realise I had typed the entire first column as ones, and I also need to stop doing these things at 3 in the morning
You had this:
p0101
==========
q0011
==========
p xor q1110
That's NOR.
p0101
==========
q0011
==========
p xor q1110
That's NOR.
The first time he had all 1s at the bottom... which is... umm... nothing that I know of (certainly nothing useful if it does exist)
Well, if we all agree that the information that is on lesson 4 is complete and accurate, I will begin work on lesson 5. Lesson 5 is about Lbl's and Goto's so it should not take long to rewrite that lesson, and move onto the next.
I am hopefully going to the library for an hour or so tonight, so I might even get most of the way complete with lesson 6. I have a 4.3GB file that I am torrenting, so hopefully an hour at the library will help speed that along, as I have about 8 hours on dialup, and only 1.2% of the download completed.
I am hopefully going to the library for an hour or so tonight, so I might even get most of the way complete with lesson 6. I have a 4.3GB file that I am torrenting, so hopefully an hour at the library will help speed that along, as I have about 8 hours on dialup, and only 1.2% of the download completed.
» Goto page Previous 1, 2, 3, 4, 5 Next
» View previous topic :: View next topic
» View previous topic :: View next topic
Page 3 of 5
» All times are UTC  5 Hours
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Advertisement