On Thu, Aug 5, 2010 at 00:16, HACKER Nora wrote:
> Hi,
>
> Additional noob question: What would be wrong with
>
> $version = '0'.$version;
snip
Do you always want one 0 in front of version? What if the version is
9? Shouldn't it be "009" then? You could write:
#version should be th
Hi,
Additional noob question: What would be wrong with
$version = '0'.$version;
?
LG,
Nora
> -Ursprüngliche Nachricht-
> Von: Shawn H Corey [mailto:shawnhco...@gmail.com]
> Gesendet: Donnerstag, 05. August 2010 01:58
> An: beginners@perl.org
> Betreff: Re: Is this perl sta
On Wed, Aug 4, 2010 at 11:36, Mike Martin wrote:
snip
> This fails but if I replace
> $type_g=$options{$key}->[4] if $chk=~/$type/
>
> with either
> $type_g=$options{$key}->[4] if $type=~/$chk/; (ie:reversing the match)
>
> or
>
> $type_g=$options{$key}->[4] if $type eq $chk;
>
> any idea on the r
I have been working on a script that imports a number of pictures into
powerpoint edits some text and saves the presentation out. The main
program works fine but there are some annoying things that happen with
the application.
I am creating the application with:
my $app = Win32::OLE->new('PowerPo
On Wed, Aug 4, 2010 at 12:09, Sooraj S wrote:
> Hi,
>
> My script has 3 options which recieve integers. If any of those
> options are having a value which is less than zero i want to make them
> to 100.
>
> eg: if opt2 = 32 and opt3 = 24 i want to make them to 100.
>
> code
> =
> our $opt1,$op
Mike Martin wrote:
Hi
Hello,
I have the following code
my $type='val';
my $type_g;
foreach my $key (keys %options){
my $chk=$options{$key}->[3];
$type_g=$options{$key}->[4] if $chk=~/$type/;
#$type_g=$options{$key}->[4] if $type=~/$chk/;
}
print "\n",$type,"\t",$type_g,"\n";
This fails but i
Mornin' Sooraj,
As is true of most "does this work in Perl" questions, the answer is "Try it" --
C:\Documents and Settings\Administrator>perl -e
"$version=9;$version=sprintf(\"0%d\",$version); print $version; "
09
C:\Documents and Settings\Administrator>
Enjoy ---
B
On Wed, Aug 4, 2010 at 4:5
2010/8/5 Noah :
> Hi there,
>
> is there a perl module that does a decent job converting an ipv4 address to
> an ipv6 address?
>
Maybe this one?
http://search.cpan.org/~manu/Net-IP-1.25/IP.pm
--
Jeff Pang
http://home.arcor.de/pangj/
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For
On 10-08-04 05:39 AM, Sooraj S wrote:
Hi,
My code is accepting an option "version" as an integer. If it is less
than 100, i need to add a zero in front of it so that i can do the
further processing.
Although this code is working, i am not sure that its the proper way.
if ($version< 100)
{
Hi,
My script has 3 options which recieve integers. If any of those
options are having a value which is less than zero i want to make them
to 100.
eg: if opt2 = 32 and opt3 = 24 i want to make them to 100.
code
=
our $opt1,$opt2,$opt3;
our @opt = (\$opt1,\$opt2,\$opt3);
GetOptions('opt1=i'
Hi
I have the following code
my $type='val';
my $type_g;
foreach my $key (keys %options){
my $chk=$options{$key}->[3];
$type_g=$options{$key}->[4] if $chk=~/$type/;
#$type_g=$options{$key}->[4] if $type=~/$chk/;
}
print "\n",$type,"\t",$type_g,"\n";
This fails but if I replace
$type_g=$options{$ke
Hi,
My code is accepting an option "version" as an integer. If it is less
than 100, i need to add a zero in front of it so that i can do the
further processing.
Although this code is working, i am not sure that its the proper way.
if ($version < 100)
{
# convert an integer-variable to string
On Wed, Aug 4, 2010 at 14:47, Noah wrote:
> Hi there,
>
> is there a perl module that does a decent job converting an ipv4 address to
> an ipv6 address?
snip
There are [several mechanisms][0] for interoperability between ipv4
and ipv6 networks. Can you be more specific?
[0]: http://en.wikipedi
Hi there,
is there a perl module that does a decent job converting an ipv4 address
to an ipv6 address?
Cheers,
Noah
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/
On 4 August 2010 01:59, Rob Dixon wrote:
>
> Speed of execution is the last goal of all.
>
> First of all make your program functional and intelligible.
>
> Only after that, if you have problems with resources (including time, disk
> space, or processor) tune it to be more efficient.
This, a thou
15 matches
Mail list logo