2

I am trying to execute this code:

#!C:\python-3.7.0-embed-amd64\python.exe

print('Content-type: text/html\r\n')
print('\r\n')
print('Hello, World!')

and I got this error:

Server error!
The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there was an error in a CGI script.

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

Error 500
localhost
Apache/2.4.33 (Win32) OpenSSL/1.1.0h PHP/7.2.6

What could be causing this problem?

1 Answer 1

3

Make sure there is no white space or tab characters before the shebang (#!). That was my issue.

It must be at the first character position of the file.

Sign up to request clarification or add additional context in comments.

1 Comment

This was the issue for me.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.