Coyote has asked for the wisdom of the Perl Monks concerning the following question:
When I run the command foo.pl -F %s:\t%s\n, I get foo:\tbar\n. printf is treating $opt_F as a single quoted string. Is there anyway I can coerce the single quoted string into a double quotish string that will properly interpolate the \t and \n characters?#!/usr/bin/perl -w use strict; use Getopt::Std; use vars qw($opt_F); getopts('F:'); printf($opt_F, 'foo', 'bar');
----
Coyote
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Changing a single quoted string into an interpolated string
by busunsl (Vicar) on Aug 28, 2001 at 00:36 UTC | |
by Coyote (Deacon) on Aug 28, 2001 at 00:42 UTC |