You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect((HOST, PORT))
data = s.recv(4)
#! These lines are used for debug purpose !#
#print data
#print repr(data)
#print data.encode('hex')
number = struct.unpack("I", data)[0] #convert hex_string (string of an integer, in LITTLE-ENDIAN) received from server (or another client) to an integer