i need to create a turbo c program that enables me to generate a truth table..

the program must be able to compare various relationship such as "AND" "OR" "NEGATION" "double NEGATION"
there is one good example of the program that i need that i saw in this site like this one.. at:

http://www-cs-students.stanford.edu/~silver/truth/


on this site i saw the one that i need.. please help me create one of this on a turbo c program..

if you can lend me some codes thanks!!

Well, first, do you know anything about parsing, or just about recursion? Because you'll have to use a bit of that, for your program to understand the expressions the user types in.

Member Avatar for iamthwee

You need to write your own grammer to parse and evalute the functions. Not necessarily an easy feat in c.

#include stdio.h
Member Avatar for iamthwee
#include stdio.h

That isn't a standard c header file.

turbo C isn't a standard C compiler :)

Well, first, do you know anything about parsing, or just about recursion? Because you'll have to use a bit of that, for your program to understand the expressions the user types in.

i just dont have idea about parsing and even that recursion thing.. i just heard on the 4th years that recursions is for functions and i dont even have idea on using those.. i only have limited resources of syntax with just looping statements, switch, conditional statements, arithmetic operation and one dimentional array thats all my resources and those you've mention are new to me.. and i just want to immitate this site because this is the one that i need,,

http://www-cs-students.stanford.edu/~silver/truth/

Member Avatar for iamthwee

>i only have limited resources of syntax with just looping statements, switch, conditional statements, arithmetic operation and one dimentional array thats all my resources and those you've mention are new to me.

Maybe you need to try something easier?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.