Announcement

Collapse
No announcement yet.

Puzzle between lower and upper case

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Puzzle between lower and upper case

    Hi all,

    Recently I was writing a program that uses e and E as variables
    only to find at after calculating e and then calculating E the
    program placed E to the variable e. I thought that e and E would
    be separate variables. Could someone enligthen me.

    Fred

    ------------------

  • #2
    The BASIC language is not case sensitive.


    ------------------

    Comment


    • #3
      To expand a little on Jose's response:

      "variable$", "Variable$" and "VARIABLE$" are all the same to
      a basic compiler.

      A good work around, in your case, would be e1$, e2$, etc. just
      keeping in mind that caps are immaterial.


      ------------------
      There are no atheists in a fox hole or the morning of a math test.
      If my flag offends you, I'll help you pack.

      Comment


      • #4
        $DIM ALL would have forced you to use LOCAL on both E and e and caught that with a '466 duplicate name definition' error

        (Actually, just 'LOCAL E AS LONG, e AS LONG' catches this even without $DIM ALL.)




        [This message has been edited by Michael Mattias (edited September 15, 2003).]
        Michael Mattias
        Tal Systems Inc. (retired)
        Racine WI USA
        [email protected]
        http://www.talsystems.com

        Comment

        Working...
        X