Help for this page

Select Code to Download


  1. or download this
    use warnings;
    use strict;
    
    my @arr = qw(book dog cat);
    print "['", join( "','", @arr), "'];\n";
    
  2. or download this
    print "[",
          ( @arr2 ? "'" . join( "','", @arr2) . "'" : ''),
          "];\n";