The use strict; Statement in Perl

The Perl programming language started as a hack, as a tool that its sole purpose was to fulfill specific needs. When Perl’s popularity grew and more and more people started to use it was already too late to enforce rigid grammar rules. Adding the ‘use strict;’ statement in the beginning of the file will enforce the language rigid rules.

#!/usr/bin/perl
use strict;
use warnings FATAL => 'all';

my $a = 3;
my $b = 4;
my $c = $a+$b;
print($c);

Share:

The Visitor Design Pattern

The Visitor Design Pattern

The visitor design pattern allows us to add operations to objects that already exist without modifying their classes and without extending them.

The Beauty of Code

Coding is Art! Developing Code That Works is Simple. Develop Code with Style is a Challenge!

Update cookies preferences