develooper Front page | perl.beginners | Postings from December 2002

Constants and Hash Question

Thread Next
From:
Paul Kraus
Date:
December 11, 2002 06:17
Subject:
Constants and Hash Question
Message ID:
01f401c2a11f$f055fb20$64fea8c0@pkrausxp
I am declaring my constants like this.
use constant SOURCE => "/path/folder/"
Now how would I use this constant is a print statement or any statement
for that matter.
print "$SOURCE" does not work and of course print "source" will not
work.


I understand that this works but I do not understand what its doing and
the need for the parenthesis.
Could someone explain this statement for me. I have put <> around the
part I don't understand.

this is part of a tied hash for Config::IniFiles.
--=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
while (($k,$v) = each <%{$ini{$section}}>)

Paul Kraus
Network Administrator
PEL Supply Company
216.267.5775 Voice
216.267.6176 Fax
www.pelsupply.com

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About