使用 socket 类创建一个套接字对象 使用 connect((host,port))设置连接的主机 IP 和主机设置的端口 使用 recv()/send()方法接收和发送数据 使用 close()关闭套接字