hope this fix your issue The connection is established and waiting for you to enter a command. Type GET / HTTP/1.0 and press Enter twice. The command is case-sensitive. It's not displayed as you type, because localecho is off by default. You can enable localecho like this:
Welcome to Microsoft Telnet Client
Escape Character is 'CTRL++'
Microsoft Telnet> set localecho
Local echo on
Microsoft Telnet> open www.example.com 80
Connecting To www.example.com...
GET / HTTP/1.0
How to print the whole file line by line with `for line in f:`, including a possibly incomplete last line?