最简单的方法是从内到外构建字典:
tree_dict = {}for key in reversed(tree_list): tree_dict = {key: tree_dict}
上一篇 熊猫:无法写入Excel文件
下一篇 使用Python的socket.gethostbyaddr()困难
版权所有 (c)2021-2022 MSHXW.COM
ICP备案号:晋ICP备2021003244-6号