Help for this page

Select Code to Download


  1. or download this
    printf("%06d\n",$_) for (123, 1234, 12345, 123456);
    
    my $val = sprintf("%06d",123);
    
  2. or download this
    my $name = '012345';
    my ($three) = $name =~ /^(\d\d\d)/;
    
  3. or download this
    use strict;
    
    ...
    1234.jpg
    12345.jpg
    123456.jpg