Python Tips & Tricks:

Ice Cream and Pickles

1) Ice Cream

^^^ Icecream outputs automatically include the referenced variable.

2)Pickling

Pickling:

“a serialized, byte-wise .pkl file that preserves a Python object precisely and exactly”

Step 1: Import Pickle
Step 2: Opening the file for writing
Step 3: Putting the jar on the Lid
Step 4: Unpickling a File
Our food dictionary unpickled.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store