in reply to String interpolation

use " instead of ':
my $str = "params.$idx.arg";

That means for your code:
for(0..10){ my $str = "params.$idx.arg"; do_something($str); }

Replies are listed 'Best First'.
A reply falls below the community's threshold of quality. You may see it by logging in.