in reply to Possible to use variable in printf statement?

Yes, it is possible. One way to do it...
my $v = 20; printf "%${v}s", 'foo';