I'm trying to unpack bytes in python :-
import struct
c_struct_exp='struct lokesh { int i=5;} lm;'
result=struct.unpack('!i',bytes(c_struct_exp,'utf-8'))
print(result)
error:
struct.error: unpack requires a bytes object of length 4
please, help me with format string expression in unpack method.