gannett has asked for the wisdom of the Perl Monks concerning the following question:
andperl -e 'print 312023," ",312," ",23,"\n";' 312023 312 23
In the second example the third part "023" is interpreted as octal ( base 7 ) and becomes 2*8+3 decimal 19. I am neutral about 0x23 interpreted as hexadecimal but can this ancient octal feature of perl be switched off ?perl -e 'print 312023," ",312," ",023,"\n";' 312023 312 19
|
|---|