Thread: put (a<d) AND (b<c) AND (c<d) into an expression tree

  1. #1
    Registered User mlupo's Avatar
    Join Date
    Oct 2001
    Posts
    72

    put (a<d) AND (b<c) AND (c<d) into an expression tree

    This is a C data structure thing.

    Would the proper representation of this be:
    Code:
                AND
               /  \
              /    \
             <     AND
            /\      /\
           a  d    <  \
                  /\   <
                 b  c  /\
                      c  d

    Thanks,
    Mike
    Last edited by mlupo; 12-02-2002 at 09:19 PM.
    NEVER PET YOUR DOG WHILE IT'S ON FIRE!

  2. #2
    Registered User
    Join Date
    Dec 2002
    Posts
    221
    traveresed which way?

  3. #3
    Registered User mlupo's Avatar
    Join Date
    Oct 2001
    Posts
    72
    Was not specified.
    NEVER PET YOUR DOG WHILE IT'S ON FIRE!

  4. #4
    Code Goddess Prelude's Avatar
    Join Date
    Sep 2001
    Posts
    9,897
    >Was not specified.
    Then yes. That lack of detail gives you quite a bit of wiggle room.

    -Prelude
    My best code is written with the delete key.

  5. #5
    Registered User mlupo's Avatar
    Join Date
    Oct 2001
    Posts
    72
    Thanks for the confirmation.
    It's appreciated.

    Mike
    NEVER PET YOUR DOG WHILE IT'S ON FIRE!

Popular pages Recent additions subscribe to a feed