Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #IF CONNECTION = SUCCESS THEN PRINT = IT WORKS IT WILL.
- import socket
- def main():
- s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
- host = '192.168.0.28'
- port = 80
- s.connect((host, port))
- print('it works')
- s.close()
- if __name__ == '__main__':
- main()
Add Comment
Please, Sign In to add comment