>>414 use feature qw(say); use URI; use Web::Scraper; use open qw(:encoding(utf-8) :std);
my $amazon_stock = scraper { process q{//span[@id='btAsinTitle']}, title => 'TEXT'; process q{//form[@id='handleBuy']/table[3]/tr}, 'detail[]' => 'TEXT'; }; while(<>){ chomp; $_ or next; my $stock = $amazon_stock->scrape(URI->new($_)); length and say for($stock->{title}, @{$stock->{detail}}[1..3]); say ''; }