Take
use strict;
use CGI qw/:standard/;
use CGI::Carp qw/fatalsToBrowser/;
use IO:Socket;
use GD;
use XML::Simple;
add 4 lines of code. What do you get?
One dog-slow CGI. You can just hear Apache groan. And I haven't added the DBI code yet :-0
A recent project used a total of 9 modules in the main script: CGI, CGI::Carp, File::Slurp, Storable, Apache::Session, Date::Calc, Digest::MD5, Mail::Sendmail, HTML::Template, and DBI. Other parts of it used MIME::Lite, Mail::Bulkmail, Parallel::ForkManager, Email::Valid, Mail::MboxParser, Mail::Address, and Email::Find. Wow! That's not including the dependencies of these module either.
That's why I love perl. Without CPAN you're just banging your head against the wall
p.s. big thanks to the authors of the above modules.