发送信息给飞秋

from socket import *
#创建套接字
udpSoctet=socket(AF_INET,SOCK_DGRAM)
#接受方地址
sendAddress=('10.3.134.255',2425)
sendData= ('1:1:表哥:表哥:32:%s'%'下午好').encode('gbk')
udpSoctet.sendto(sendData,sendAddress)
udpSoctet.close()

猜你喜欢

转载自blog.csdn.net/weixin_42141853/article/details/80547460