in reply to Re: Re: Re: When is 111111 greater than 0222222?
in thread When is 111111 greater than 0222222?

I should say, in my defense, that this code will never have to deal with dates before '01, and unless something truly bizarre happens, won't even have to deal with dates after '05. I won't have problems until 2010.

I know that's exactly what millennium bug people thought, but seriously, an SQL database is coming long before it would be an issue, with proper dates. If all else fails I'll mass-rename and rewrite a couple of subs and all will be well again.

Can I use this space to ask what happens to my unfortunately-constructed numbers in the following circumstances:

  1. $number = '022222'
  2. $number = "022222"
  3. $number = 022222
  4. @numbers = READDIR(something); $number = $numbers[0] # assuming my file's called '022222'
?

“Every bit of code is either naturally related to the problem at hand, or else it's an accidental side effect of the fact that you happened to solve the problem using a digital computer.”
M-J D
  • Comment on Re: Re: Re: Re: When is 111111 greater than 0222222?

Replies are listed 'Best First'.
Re: Re: Re: Re: Re: When is 111111 greater than 0222222?
by The Mad Hatter (Priest) on Jul 01, 2003 at 03:10 UTC
    1. Used in numerical context, $number == 22222
    2. Used in numerical context, $number == 22222
    3. Used in numerical context, $number == 9362 (in base 10, 22222 in octal (base 8))
    4. Used in numerical context, $number == 22222 (I think)
    Is that what you want? Or did I misunderstand your questions?