#!/usr/bin/perl

##Rule of Thumb in Perl:

#If we want to compare numbers, use ==,!=,>, etc.
#If we want to compare strings, use eq, ne, lt, gt,etc.
my $a="hello";
my $b="hello";
my $c="hello 1";
my $sub_c=substr($c,0,-2);


if ($a eq $b){
	print "$a is the same as $b\n";
}
if ($a eq $sub_c){
	print "$a is almost the same as $sub_c\n";
	}

if ($a ne $c){
	print "$a is not quite the same as $c\n";
	}

if ($a eq substr($c,0,-2)){
	print "$a is the same as the substring of $c\n";

	}

if (substr($a,0,-1) eq substr ($c,0,-3)){
	print "This technique works as well \n";
	
	}
