“End of script output before headers” error in Apache

Apache on Windows gives me the following error when I try to access my Perl script:

Server error!

The server encountered an internal error and was unable to complete your request.

Error message: 
End of script output before headers: sample.pl

If you think this is a server error, please contact the webmaster.

Error 500

localhost
Apache/2.4.4 (Win32) OpenSSL/1.0.1e PHP/5.5.3

this is my sample script

#!"C:\xampp\perl\bin\perl.exe"
print "Hello World";

but not working on browser

Leave a Comment