Python: How to read a text file into a dictionary when each key and value is on a new line?

前端 未结 0 1108
长发绾君心
长发绾君心 2020-11-21 04:37

I\'m sure there is an example of this somewhere already but I haven\'t been able to find it. I have a text file that looks like this:

apple
1
orange

相关标签:
回答
  • 消灭零回复
提交回复
热议问题