#! /usr/bin/perl -w use strict; my $a = ; $a =~ (m/\d\d\.\d\d/) || (m/\$\d\d\d\.\d\d\d/) || (m/\$\.\d\d/); print "$a is true";