4 Replies - 7122 Views - Last Post: 23 October 2010 - 12:05 PM Rate Topic: -----

#1 Moslema   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 07-January 10

How to implement Truth Table using windows application

Posted 19 October 2010 - 05:23 AM

Hi every body!!!!!!!!
:smile2:
i need your help in how to implement a truth table(for propositional logic)using windows application
i tried to recieve user statement in a text box (a statement like "A&B<-->c")
but i don't know how to make computer understand it splitted like 'A' is a symbol '&' is an operand and how to make operations in each char alone?????????????
:stupid:

Is This A Good Question/Topic? 0
  • +

Replies To: How to implement Truth Table using windows application

#2 FlashM   User is offline

  • D.I.C Lover
  • member icon

Reputation: 383
  • View blog
  • Posts: 1,195
  • Joined: 03-December 09

Re: How to implement Truth Table using windows application

Posted 19 October 2010 - 05:35 AM

I believe you will need to parse the string in a textbox char by char and look for your operands and operators... Then having some select case statement to determine what it char read will do... something like that... Take a look at how to build a calculator and it might give you some clue or a starting point... You can find lots of tutorials here on our site... If you get stuck, just drop us a line.
Was This Post Helpful? 1
  • +
  • -

#3 Curtis Rutland   User is offline

  • (╯□)╯︵ (~ .o.)~
  • member icon


Reputation: 5106
  • View blog
  • Posts: 9,283
  • Joined: 08-June 10

Re: How to implement Truth Table using windows application

Posted 19 October 2010 - 07:00 AM

Flash's suggestion about building a calculator is quite the good one. After all, this is a certain type of calculator anyway, right?

As a side note: Please don't make your posts any harder to read than they need to be. Remember that most of the people you want to help you are professionals, and they are not going to be impressed by different colors and fonts and text alignments.
Was This Post Helpful? 1
  • +
  • -

#4 Robin19   User is offline

  • D.I.C Addict
  • member icon

Reputation: 272
  • View blog
  • Posts: 552
  • Joined: 07-July 10

Re: How to implement Truth Table using windows application

Posted 19 October 2010 - 07:02 AM

There is also a tutorial for Reverse Polish Notation. It won't work exactly the way you want it to, but it is a good tutorial in turning text to math.
Was This Post Helpful? 1
  • +
  • -

#5 Moslema   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 07-January 10

Re: How to implement Truth Table using windows application

Posted 23 October 2010 - 12:05 PM

View PostinsertAlias, on 19 October 2010 - 06:00 AM, said:

Flash's suggestion about building a calculator is quite the good one. After all, this is a certain type of calculator anyway, right?

As a side note: Please don't make your posts any harder to read than they need to be. Remember that most of the people you want to help you are professionals, and they are not going to be impressed by different colors and fonts and text alignments.

Thank you "insertAlias" for your advice but sorry i am not very good in english ( :unsure: )
and i am sorry if i made some trouble here...
and THANKS VERY MUCH TO EVERY ONE HELPS ME :flowers:

This post has been edited by Moslema: 23 October 2010 - 12:11 PM

Was This Post Helpful? 0
  • +
  • -

Page 1 of 1