# ---> is used for comment
helloworld.pl
print"Hello World";
helloname.pl
print"Enter your name : ";
$n=; # to get input
chomp $n; # to remove the trailing spaces in the statement
print"Hello $n. How are you doing?";
Addition of two numbers
print"Enter value of a : ";
$a=;
print"Enter value of b : ";
$b=;
$c=$a+$b;
print"Answer is $c";
helloworld.pl
print"Hello World";
helloname.pl
print"Enter your name : ";
$n=
Addition of two numbers
print"Enter value of a : ";
$a=
print"Enter value of b : ";
$b=
$c=$a+$b;
print"Answer is $c";
No comments:
Post a Comment