#!/usr/bin/perl use strict; use warnings; my $x1 = 44.7; my $x2 = 44.9-0.2; print "numbers $x1 $x2 - "; if ($x1 == $x2) { print "SAME\n"; } else { print "NOT SAME\n"; }