#!/usr/bin/perl -wif (is_windows() ) { print "We are running under Windows.\n"; }print "The OS name is $^O\n";sub is_windows() { return $^O =~ /^(MS)?Win/;}