Answers for "saving dict to file python"

0

python save dictionary to file

with open('saved_dictionary.pkl', 'wb') as f:
    pickle.dump(dictionary, f)
        
with open('saved_dictionary.pkl', 'rb') as f:
        loaded_dict = pickle.load(f)
Posted by: Guest on December-01-2021

Python Answers by Framework

Browse Popular Code Answers by Language