#!/usr/bin/perl -w # Print all doi dlib urls use strict; open(URLS, "urls_by_article_complete.txt") || die($!); while (my $line = ) { # Ignore article urls next if ($line !~ m|^\t|); chomp($line); my ($url) = $line =~ /^\t(.+)/; print "$url\n" if ($url =~ m|http://dx.doi.org/10.1045/|); } close URLS;