aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xchallenge-028/veesh-goldman/perl5/ch-01.pl14
1 files changed, 14 insertions, 0 deletions
diff --git a/challenge-028/veesh-goldman/perl5/ch-01.pl b/challenge-028/veesh-goldman/perl5/ch-01.pl
new file mode 100755
index 0000000000..792819987d
--- /dev/null
+++ b/challenge-028/veesh-goldman/perl5/ch-01.pl
@@ -0,0 +1,14 @@
+#! /usr/bin/env perl
+
+use v5.22;
+
+#activate slurp mode
+local $/;
+while (<>) {
+ #print the name of the file we're checking
+ print "$ARGV - ";
+ say 'The file content is binary' and next if /[[^:ascii:]]/;
+ say 'The file content is ascii'
+}
+
+