truth table Give some help in "&"

Post Reply
User avatar
Matheusfarias
Posts: 17
Joined: Mon Sep 10, 2012 1:55 pm
Location: João Pessoa/Paraiba/Brasil
Contact:

truth table Give some help in "&"

Post by Matheusfarias »

need to make a truth table my code works this way: :P

Code: Select all | Expand


#Include "Fivewin.ch"
 #command ~  => !
 #command ^  => .AND.
 #command V  => .or.
 #command <a> &'<->' <b> => if ( a=b , .t. , .f. )
 #command <a> -> <b> => if ( b , if ( a , .t. , .t.) , if ( a , .f. , .t. ))
FUnction main()

vpropos:="q ^ b"
 
if &vpropos  // Error
   msginfo("1")
endif

if q ^ b // no error
   msginfo("1")
endif

         
 


I read on some forums and saw that the macro does not work with the command # and # translante
could someone give me an idea, I need a job for the university


:D :D :D :D :D :D
User avatar
Antonio Linares
Site Admin
Posts: 42409
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Has thanked: 12 times
Been thanked: 48 times
Contact:

Re: truth table Give some help in "&"

Post by Antonio Linares »

Try with #define instead of #command and without the arrow
regards, saludos

Antonio Linares
www.fivetechsoft.com
Post Reply