Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

I think you are trying to say a "but" operator is equivalent "not and" operator and that !(A->B) is equivalent to "but". I am assuming that "!" symbolizes the negation operator and "->" symbolized the if-then ( or implies ) operator.

Yet ...

PQP and Q!(P and Q)
So I would say "A and !B"is not equivalent to "!(A -> B)" and I wouldn't say "A but B" <=> "A and !B", but I could just be misunderstanding your notation. :)

As far a what a but operator is I would say it should be equivalent to the "Boolean And" operator. And is not needed in a programming language. The word "but" is used in commonly to emphasis that an assumption is false. Example ...

If a student where to errorously assume that multiplaction is 
the same as addition the student might state ...

1 + 1 = 2 and 2 + 2 = 4 and 2 * 2 = 4 and 1 * 1 = 2

... which we know to be false.  The student's teacher would say ...

1 + 1 = 2 and 2 + 2 = 4 and 2 * 2 = 4 but 1 * 1 != 2

... to correct the student.

This is the same as

1 + 1 = 2 and 2 + 2 = 4 and 2 * 2 = 4 and 1 * 1 != 2

    T and T and T and T is TRUE

It is not equal to

1 + 1 = 2 and 2 + 2 = 4 and 2 * 2 = 4 and not (1 * 1 != 2)

     T and T and T and F is FALSE

But merely gives emphasis to the fact that the student's assumption is false.

Janitored by davido: removed excess spaces within pre tags that caused horizontal scrolling.

Plankton: 1% Evil, 99% Hot Gas.

In reply to Re^4: A "but" operator. by Plankton
in thread A "but" operator. by muba

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?

    What's my password?
    Create A New User
    [Corion]: choroba: You went drinking with them?
    [choroba]: No, but going fully functional is like drinking a bottle of spirits

    How do I use this? | Other CB clients
    Other Users?
    Others making s'mores by the fire in the courtyard of the Monastery: (3)
    As of 2017-12-11 10:24 GMT
    Find Nodes?
      Voting Booth?
      What programming language do you hate the most?

      Results (289 votes). Check out past polls.