guys need some help in making a circuit calculator in C##

bokiratx's Avatar
Light Poster
guy i really need your help like how can i make a circuit calculator in c##, it goes like this opperator are *=and +=or ang'=not or inverter exaxples here: t*f=f, or F+t=t and F'*t=t,
guys realy need your help i'm so confused and dont know what to do...

thanks.
0
DaWei's Avatar, Join Date: Dec 2006
Team Leader
You have your LHS and RHS backwards. C##???

*= and += are merely syntactical shortcuts. A += 5 means A = A+5. Similarly for other operators.
0
bokiratx's Avatar
Light Poster
no like asterisc(*) means AND, plus(+) means ARE and appostrophe(') means not its like reading circuit logics or like "The laws of thoughts"
0
bokiratx's Avatar
Light Poster
and "f" in the example is false ant "t" in the example is true
0
DaWei's Avatar, Join Date: Dec 2006
Team Leader
In C++, logical OR is ||, logical AND is &&, logical NOT is !. There are bit-wise equivalents if you want to operate on bits, |, &, and ~, respectively.
0
bokiratx's Avatar
Light Poster
thanks dawei your a big help thanks!
0
bokiratx's Avatar
Light Poster
dawei...so what you mean is that i will assign each characters with the characters in c## ?
0
DaWei's Avatar, Join Date: Dec 2006
Team Leader
Again, what is C##? I never heard of it. One can make a program that evaluates logic (even hardware logic) in any decent language. The language has to exist, of course, or be invented.
0
bokiratx's Avatar
Light Poster
thanx thats C++ sowi