#!/usr/bin/perl use warnings; use strict; my @liste = ("1", "2", "3"); $liste[1] = sprintf("%03d", $liste[1]); print join("\n", @liste)."\n";