Python中msgpack库如何使用?

本文教程操作环境:windows7系统、Python 3.9.1,DELL G3电脑。

库安装:

pipinstallmsgpack

导入使用:

importmsgpack

使用操作:

importmsgpack

var={'a':'this',
'b':'is',
'c':'atest'
}
print(var)

输出结果:

{'a':'this','b':'is','c':'atest'}