これが私のコードです
#!usr/bin/env perl
# Setup includes
use strict;
use XML::RSS;
use LWP::Simple;
# Declare variables for URL to be parsed
my $url2parse;
# Get the command-line argument
my $arg = shift;
# Create new instance of XML::RSS
my $rss = new XML::RSS;
# Get the URL, assign it to url2parse, and then parse the RSS content
$url2parse = get($arg);
die "Could not retrieve $arg" unless $url2parse;
$rss->parse($url2parse);
# Print the channel items
foreach my $item (@{$rss->{'items'}}) {
next unless defined($item->{'title'}) && defined($item->{'link'});
print "<li><a href=\"$item->{'link'}\">$item->{'title'}</a><BR>\n";
}
%perl myRss.pl http://www.nytimes.com/services/xml/rss/userland/Education.xmlと入力すると、コンソールがしばらく実行 され、「 http://www.engadgetを取得できませんでした。 com/rss.xmlの myRss.pl 行 14." 私のコードはどこで間違っていますか?