Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Hclient import socket, pickle s = socket. socket(socket.AF_INET, socket.SOCK_STREAM) s.connect(('localhost', 50007)) # Pickle the object and send it to the server list=[one, two] data string
Hclient import socket, pickle s = socket. socket(socket.AF_INET, socket.SOCK_STREAM) s.connect(('localhost', 50007)) \# Pickle the object and send it to the server list=["one", "two"] data string = pickle.dumps(list) 5.send(data_string) s. clos) \#server import socket, pickle s= socket.socket(socket.AF INET, socket.SOCK_STREAM) s. bind (("localhost', 50007)) s.listen(1) conn, addr = s.accept () data = conn.recv (40) v= pickle.loads(data) conn.close() print (v[0],v[1]) Answer Q2(10 points) write the class so that the following code executes Obj =A(1,2) fun 1() \). fun 2((1,2)). fun3 (3)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started