print "Author to search for:"; chomp($search = ); open (INPUT, "books.txt"); while (){ chomp $_; ($title, $author, $genre, $price) = split /:/,$_; if ($search == $author) { $totalprice += $price; @info = ($title, $genre, $price); $found++; } } print "$found books by $author were found...\n"; print "They are:\n"; print "\tBook Title\t\t\tGenre\tPrice"; print @info; print "\tTotal price of these books by $seach is $totalprice"; close INPUT;