1c. Scalar: constant

In Perl, you can define constants using the constant pragma. Here's how you can do it:
use constant PI => 3.14159; # name in uppercase without sigil $
use constant GREETING => "Hello, world!"; # name in uppercase without sigil $

print "The value of PI is: " . PI . "\n";
print GREETING . "\n";
You can then use these constants throughout your code, and their values cannot be changed.
use constant PHI => 1.62;
PHI++; # Error message: Can't modify constant item in scalar assignment at ...
Constants can be redeclared. Use the following pragma to prevent mistakes: you get a warning if you redeclare a constant:
use warnings;
Notice that sometimes constants are declared with an asterisk and a reference to a value:
*PHI = \1.62; # The same as: use constant PHI => 1.62;